@atlaskit/editor-common 118.7.0 → 118.9.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.
Files changed (39) hide show
  1. package/CHANGELOG.md +36 -0
  2. package/afm-cc/tsconfig.json +3 -0
  3. package/afm-products/tsconfig.json +3 -0
  4. package/connectivity/isOfflineMode/package.json +10 -0
  5. package/connectivity/mode/package.json +10 -0
  6. package/dist/cjs/ai-messages/ai-suggestions.js +10 -0
  7. package/dist/cjs/connectivity/isOfflineMode.js +12 -0
  8. package/dist/cjs/connectivity/mode.js +1 -0
  9. package/dist/cjs/monitoring/error.js +1 -1
  10. package/dist/cjs/provider-helpers/combine-providers.js +35 -1
  11. package/dist/cjs/quick-insert/getQuickInsertProviderMenuItemKey.js +9 -0
  12. package/dist/cjs/quick-insert/rank.js +2 -1
  13. package/dist/cjs/ui/DropList/index.js +1 -1
  14. package/dist/es2019/ai-messages/ai-suggestions.js +10 -0
  15. package/dist/es2019/connectivity/isOfflineMode.js +6 -0
  16. package/dist/es2019/connectivity/mode.js +0 -0
  17. package/dist/es2019/monitoring/error.js +1 -1
  18. package/dist/es2019/provider-helpers/combine-providers.js +11 -1
  19. package/dist/es2019/quick-insert/getQuickInsertProviderMenuItemKey.js +1 -0
  20. package/dist/es2019/quick-insert/rank.js +1 -0
  21. package/dist/es2019/ui/DropList/index.js +1 -1
  22. package/dist/esm/ai-messages/ai-suggestions.js +10 -0
  23. package/dist/esm/connectivity/isOfflineMode.js +6 -0
  24. package/dist/esm/connectivity/mode.js +0 -0
  25. package/dist/esm/monitoring/error.js +1 -1
  26. package/dist/esm/provider-helpers/combine-providers.js +35 -1
  27. package/dist/esm/quick-insert/getQuickInsertProviderMenuItemKey.js +3 -0
  28. package/dist/esm/quick-insert/rank.js +1 -0
  29. package/dist/esm/ui/DropList/index.js +1 -1
  30. package/dist/types/ai-messages/ai-suggestions.d.ts +10 -0
  31. package/dist/types/connectivity/isOfflineMode.d.ts +5 -0
  32. package/dist/types/connectivity/mode.d.ts +1 -0
  33. package/dist/types/provider-factory/quick-insert-provider.d.ts +3 -0
  34. package/dist/types/provider-helpers/combine-providers.d.ts +1 -0
  35. package/dist/types/quick-insert/QuickInsertContext.d.ts +1 -0
  36. package/dist/types/quick-insert/getQuickInsertProviderMenuItemKey.d.ts +1 -0
  37. package/dist/types/quick-insert/rank.d.ts +1 -0
  38. package/package.json +2 -1
  39. package/quick-insert/get-provider-menu-item-key/package.json +10 -0
package/CHANGELOG.md CHANGED
@@ -1,5 +1,41 @@
1
1
  # @atlaskit/editor-common
2
2
 
3
+ ## 118.9.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [`60e1e4cb2e065`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/60e1e4cb2e065) -
8
+ [ux] Update the Rovo ready bar to show a text Close button before the View button when a View
9
+ action is available. Show the longer Suggested Edits ready message. Gate behind the
10
+ `rovo_ready_bar_ui_update` feature gate.
11
+
12
+ ### Patch Changes
13
+
14
+ - Updated dependencies
15
+
16
+ ## 118.8.0
17
+
18
+ ### Minor Changes
19
+
20
+ - [`c0cf420333ef1`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/c0cf420333ef1) -
21
+ Add public registration APIs for provider-backed Quick Insert components.
22
+
23
+ Providers can expose registered items directly:
24
+
25
+ ```tsx
26
+ const getComponents = async () => [
27
+ {
28
+ key: 'insert-table',
29
+ component: TableItem,
30
+ parents: [{ type: 'menu-section', key: 'quick-insert', rank: 1 }],
31
+ },
32
+ ];
33
+ ```
34
+
35
+ ### Patch Changes
36
+
37
+ - Updated dependencies
38
+
3
39
  ## 118.7.0
4
40
 
5
41
  ### Minor Changes
@@ -82,6 +82,9 @@
82
82
  {
83
83
  "path": "../../editor-toolbar-model/afm-cc/tsconfig.json"
84
84
  },
85
+ {
86
+ "path": "../../editor-ui-control-model/afm-cc/tsconfig.json"
87
+ },
85
88
  {
86
89
  "path": "../../../elements/emoji/afm-cc/tsconfig.json"
87
90
  },
@@ -82,6 +82,9 @@
82
82
  {
83
83
  "path": "../../editor-toolbar-model/afm-products/tsconfig.json"
84
84
  },
85
+ {
86
+ "path": "../../editor-ui-control-model/afm-products/tsconfig.json"
87
+ },
85
88
  {
86
89
  "path": "../../../elements/emoji/afm-products/tsconfig.json"
87
90
  },
@@ -0,0 +1,10 @@
1
+ {
2
+ "name": "@atlaskit/editor-common/connectivity/isOfflineMode",
3
+ "main": "../../dist/cjs/connectivity/isOfflineMode.js",
4
+ "module": "../../dist/esm/connectivity/isOfflineMode.js",
5
+ "module:es2019": "../../dist/es2019/connectivity/isOfflineMode.js",
6
+ "sideEffects": [
7
+ "**/*.compiled.css"
8
+ ],
9
+ "types": "../../dist/types/connectivity/isOfflineMode.d.ts"
10
+ }
@@ -0,0 +1,10 @@
1
+ {
2
+ "name": "@atlaskit/editor-common/connectivity/mode",
3
+ "main": "../../dist/cjs/connectivity/mode.js",
4
+ "module": "../../dist/esm/connectivity/mode.js",
5
+ "module:es2019": "../../dist/es2019/connectivity/mode.js",
6
+ "sideEffects": [
7
+ "**/*.compiled.css"
8
+ ],
9
+ "types": "../../dist/types/connectivity/mode.d.ts"
10
+ }
@@ -311,11 +311,21 @@ var aiSuggestionsMessages = exports.aiSuggestionsMessages = (0, _reactIntl.defin
311
311
  defaultMessage: 'Suggestions ready',
312
312
  description: 'Text shown when the AI has finished reviewing the content'
313
313
  },
314
+ thinkingCompleteReviewCompleteUpdated: {
315
+ id: 'fabric.editor.ai.suggestions.thinkingComplete.reviewCompleteUpdated.non-final',
316
+ defaultMessage: 'Review complete, view your suggestions.',
317
+ description: 'Updated text shown when the AI has finished reviewing the content'
318
+ },
314
319
  thinkingCompleteNoSuggestions: {
315
320
  id: 'fabric.editor.ai.suggestions.thinkingComplete.noSuggestions.non-final',
316
321
  defaultMessage: 'No suggestions found',
317
322
  description: 'Text shown when the AI has finished reviewing the content and no suggestions were found'
318
323
  },
324
+ thinkingCompleteNoSuggestionsUpdated: {
325
+ id: 'fabric.editor.ai.suggestions.thinkingComplete.noSuggestionsUpdated.non-final',
326
+ defaultMessage: 'Review complete. No suggestions found.',
327
+ description: 'Updated text shown when the AI has finished reviewing the content and no suggestions were found'
328
+ },
319
329
  thinkingCompleteViewSuggestions: {
320
330
  id: 'fabric.editor.ai.suggestions.thinkingComplete.viewSuggestions.non-final',
321
331
  defaultMessage: 'View',
@@ -0,0 +1,12 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.isOfflineMode = void 0;
7
+ /**
8
+ * Check if the connectivity mode represents ANY offline state
9
+ */
10
+ var isOfflineMode = exports.isOfflineMode = function isOfflineMode(mode) {
11
+ return mode === 'offline' || mode === 'collab-offline' || mode === 'internet-offline';
12
+ };
@@ -0,0 +1 @@
1
+ "use strict";
@@ -28,7 +28,7 @@ var NETWORK_FAILURE_REGEX = /^network failure/i;
28
28
  var RESIZE_OBSERVER_LOOP_REGEX = /ResizeObserver loop completed with undelivered notifications/;
29
29
  var SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
30
30
  var packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
31
- var packageVersion = "118.6.0";
31
+ var packageVersion = "118.8.0";
32
32
  var sanitiseSentryEvents = function sanitiseSentryEvents(data, _hint) {
33
33
  // Remove URL as it has UGC
34
34
  // Ignored via go/ees007
@@ -148,8 +148,42 @@ var _default = exports.default = function _default(providers) {
148
148
  return _ref5.apply(this, arguments);
149
149
  };
150
150
  }();
151
+
152
+ // Ignored via go/ees005
153
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
154
+ var invokeOptionalList = /*#__PURE__*/function () {
155
+ var _ref6 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee5(methodName, args) {
156
+ var providersWithMethod, results, fulfilledResults;
157
+ return _regenerator.default.wrap(function (_context5) {
158
+ while (1) switch (_context5.prev = _context5.next) {
159
+ case 0:
160
+ _context5.next = 1;
161
+ return getFulfilledProviders();
162
+ case 1:
163
+ providersWithMethod = _context5.sent.filter(function (provider) {
164
+ return typeof provider[methodName] === 'function';
165
+ });
166
+ _context5.next = 2;
167
+ return (0, _promiseHelpers.waitForAllPromises)(providersWithMethod.map(createCallback(methodName, args)));
168
+ case 2:
169
+ results = _context5.sent;
170
+ fulfilledResults = (0, _promiseHelpers.getOnlyFulfilled)(results);
171
+ return _context5.abrupt("return", flatten(fulfilledResults).filter(function (result) {
172
+ return result;
173
+ }));
174
+ case 3:
175
+ case "end":
176
+ return _context5.stop();
177
+ }
178
+ }, _callee5);
179
+ }));
180
+ return function invokeOptionalList(_x6, _x7) {
181
+ return _ref6.apply(this, arguments);
182
+ };
183
+ }();
151
184
  return {
152
185
  invokeSingle: invokeSingle,
153
- invokeList: invokeList
186
+ invokeList: invokeList,
187
+ invokeOptionalList: invokeOptionalList
154
188
  };
155
189
  };
@@ -0,0 +1,9 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.getQuickInsertProviderMenuItemKey = void 0;
7
+ var getQuickInsertProviderMenuItemKey = exports.getQuickInsertProviderMenuItemKey = function getQuickInsertProviderMenuItemKey(key) {
8
+ return "quick-insert-provider-".concat(key);
9
+ };
@@ -4,7 +4,7 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
4
4
  Object.defineProperty(exports, "__esModule", {
5
5
  value: true
6
6
  });
7
- exports.TEXT_FORMATTING_SECTION_RANK = exports.STRUCTURE_SECTION_RANK = exports.ROVO_SECTION_RANK = exports.QUICK_INSERT_MENU_RANK = exports.MEDIA_SECTION_RANK = exports.DATA_AND_CHARTS_SECTION_RANK = exports.CATEGORY_VIEW_MORE_RANK = void 0;
7
+ exports.TEXT_FORMATTING_SECTION_RANK = exports.STRUCTURE_SECTION_RANK = exports.ROVO_SECTION_RANK = exports.QUICK_INSERT_MENU_RANK = exports.MEDIA_SECTION_RANK = exports.EXTENSION_ITEM_RANK = exports.DATA_AND_CHARTS_SECTION_RANK = exports.CATEGORY_VIEW_MORE_RANK = void 0;
8
8
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
9
9
  var _keys = require("./keys");
10
10
  /* eslint-disable @atlaskit/volt-strict-mode/no-multiple-exports */
@@ -15,4 +15,5 @@ var MEDIA_SECTION_RANK = exports.MEDIA_SECTION_RANK = (0, _defineProperty2.defau
15
15
  var TEXT_FORMATTING_SECTION_RANK = exports.TEXT_FORMATTING_SECTION_RANK = (0, _defineProperty2.default)((0, _defineProperty2.default)({}, _keys.UNORDERED_LIST_MENU_ITEM.key, 1100), _keys.ORDERED_LIST_MENU_ITEM.key, 1200);
16
16
  var ROVO_SECTION_RANK = exports.ROVO_SECTION_RANK = (0, _defineProperty2.default)({}, _keys.ASK_ROVO_MENU_ITEM.key, 100);
17
17
  var DATA_AND_CHARTS_SECTION_RANK = exports.DATA_AND_CHARTS_SECTION_RANK = (0, _defineProperty2.default)((0, _defineProperty2.default)({}, _keys.JIRA_WORK_ITEMS_MENU_ITEM.key, 300), _keys.ASSETS_MENU_ITEM.key, 500);
18
+ var EXTENSION_ITEM_RANK = exports.EXTENSION_ITEM_RANK = 1500;
18
19
  var CATEGORY_VIEW_MORE_RANK = exports.CATEGORY_VIEW_MORE_RANK = Number.MAX_SAFE_INTEGER;
@@ -24,7 +24,7 @@ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.
24
24
  * @jsx jsx
25
25
  */ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
26
26
  var packageName = "@atlaskit/editor-common";
27
- var packageVersion = "118.6.0";
27
+ var packageVersion = "118.8.0";
28
28
  var halfFocusRing = 1;
29
29
  var dropOffset = '0, 8';
30
30
  var fadeIn = (0, _react2.keyframes)({
@@ -305,11 +305,21 @@ export const aiSuggestionsMessages = defineMessages({
305
305
  defaultMessage: 'Suggestions ready',
306
306
  description: 'Text shown when the AI has finished reviewing the content'
307
307
  },
308
+ thinkingCompleteReviewCompleteUpdated: {
309
+ id: 'fabric.editor.ai.suggestions.thinkingComplete.reviewCompleteUpdated.non-final',
310
+ defaultMessage: 'Review complete, view your suggestions.',
311
+ description: 'Updated text shown when the AI has finished reviewing the content'
312
+ },
308
313
  thinkingCompleteNoSuggestions: {
309
314
  id: 'fabric.editor.ai.suggestions.thinkingComplete.noSuggestions.non-final',
310
315
  defaultMessage: 'No suggestions found',
311
316
  description: 'Text shown when the AI has finished reviewing the content and no suggestions were found'
312
317
  },
318
+ thinkingCompleteNoSuggestionsUpdated: {
319
+ id: 'fabric.editor.ai.suggestions.thinkingComplete.noSuggestionsUpdated.non-final',
320
+ defaultMessage: 'Review complete. No suggestions found.',
321
+ description: 'Updated text shown when the AI has finished reviewing the content and no suggestions were found'
322
+ },
313
323
  thinkingCompleteViewSuggestions: {
314
324
  id: 'fabric.editor.ai.suggestions.thinkingComplete.viewSuggestions.non-final',
315
325
  defaultMessage: 'View',
@@ -0,0 +1,6 @@
1
+ /**
2
+ * Check if the connectivity mode represents ANY offline state
3
+ */
4
+ export const isOfflineMode = mode => {
5
+ return mode === 'offline' || mode === 'collab-offline' || mode === 'internet-offline';
6
+ };
File without changes
@@ -14,7 +14,7 @@ const NETWORK_FAILURE_REGEX = /^network failure/i;
14
14
  const RESIZE_OBSERVER_LOOP_REGEX = /ResizeObserver loop completed with undelivered notifications/;
15
15
  const SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
16
16
  const packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
17
- const packageVersion = "118.6.0";
17
+ const packageVersion = "118.8.0";
18
18
  const sanitiseSentryEvents = (data, _hint) => {
19
19
  // Remove URL as it has UGC
20
20
  // Ignored via go/ees007
@@ -55,8 +55,18 @@ export default (providers => {
55
55
  const fulfilledResults = getOnlyFulfilled(results);
56
56
  return flatten(fulfilledResults).filter(result => result);
57
57
  };
58
+
59
+ // Ignored via go/ees005
60
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
61
+ const invokeOptionalList = async (methodName, args) => {
62
+ const providersWithMethod = (await getFulfilledProviders()).filter(provider => typeof provider[methodName] === 'function');
63
+ const results = await waitForAllPromises(providersWithMethod.map(createCallback(methodName, args)));
64
+ const fulfilledResults = getOnlyFulfilled(results);
65
+ return flatten(fulfilledResults).filter(result => result);
66
+ };
58
67
  return {
59
68
  invokeSingle,
60
- invokeList
69
+ invokeList,
70
+ invokeOptionalList
61
71
  };
62
72
  });
@@ -0,0 +1 @@
1
+ export const getQuickInsertProviderMenuItemKey = key => `quick-insert-provider-${key}`;
@@ -39,4 +39,5 @@ export const DATA_AND_CHARTS_SECTION_RANK = {
39
39
  [JIRA_WORK_ITEMS_MENU_ITEM.key]: 300,
40
40
  [ASSETS_MENU_ITEM.key]: 500
41
41
  };
42
+ export const EXTENSION_ITEM_RANK = 1500;
42
43
  export const CATEGORY_VIEW_MORE_RANK = Number.MAX_SAFE_INTEGER;
@@ -14,7 +14,7 @@ import withAnalyticsEvents from '@atlaskit/analytics-next/withAnalyticsEvents';
14
14
  import { fg } from '@atlaskit/platform-feature-flags';
15
15
  import Layer from '../Layer';
16
16
  const packageName = "@atlaskit/editor-common";
17
- const packageVersion = "118.6.0";
17
+ const packageVersion = "118.8.0";
18
18
  const halfFocusRing = 1;
19
19
  const dropOffset = '0, 8';
20
20
  const fadeIn = keyframes({
@@ -305,11 +305,21 @@ export var aiSuggestionsMessages = defineMessages({
305
305
  defaultMessage: 'Suggestions ready',
306
306
  description: 'Text shown when the AI has finished reviewing the content'
307
307
  },
308
+ thinkingCompleteReviewCompleteUpdated: {
309
+ id: 'fabric.editor.ai.suggestions.thinkingComplete.reviewCompleteUpdated.non-final',
310
+ defaultMessage: 'Review complete, view your suggestions.',
311
+ description: 'Updated text shown when the AI has finished reviewing the content'
312
+ },
308
313
  thinkingCompleteNoSuggestions: {
309
314
  id: 'fabric.editor.ai.suggestions.thinkingComplete.noSuggestions.non-final',
310
315
  defaultMessage: 'No suggestions found',
311
316
  description: 'Text shown when the AI has finished reviewing the content and no suggestions were found'
312
317
  },
318
+ thinkingCompleteNoSuggestionsUpdated: {
319
+ id: 'fabric.editor.ai.suggestions.thinkingComplete.noSuggestionsUpdated.non-final',
320
+ defaultMessage: 'Review complete. No suggestions found.',
321
+ description: 'Updated text shown when the AI has finished reviewing the content and no suggestions were found'
322
+ },
313
323
  thinkingCompleteViewSuggestions: {
314
324
  id: 'fabric.editor.ai.suggestions.thinkingComplete.viewSuggestions.non-final',
315
325
  defaultMessage: 'View',
@@ -0,0 +1,6 @@
1
+ /**
2
+ * Check if the connectivity mode represents ANY offline state
3
+ */
4
+ export var isOfflineMode = function isOfflineMode(mode) {
5
+ return mode === 'offline' || mode === 'collab-offline' || mode === 'internet-offline';
6
+ };
File without changes
@@ -20,7 +20,7 @@ var NETWORK_FAILURE_REGEX = /^network failure/i;
20
20
  var RESIZE_OBSERVER_LOOP_REGEX = /ResizeObserver loop completed with undelivered notifications/;
21
21
  var SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
22
22
  var packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
23
- var packageVersion = "118.6.0";
23
+ var packageVersion = "118.8.0";
24
24
  var sanitiseSentryEvents = function sanitiseSentryEvents(data, _hint) {
25
25
  // Remove URL as it has UGC
26
26
  // Ignored via go/ees007
@@ -141,8 +141,42 @@ export default (function (providers) {
141
141
  return _ref5.apply(this, arguments);
142
142
  };
143
143
  }();
144
+
145
+ // Ignored via go/ees005
146
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
147
+ var invokeOptionalList = /*#__PURE__*/function () {
148
+ var _ref6 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee5(methodName, args) {
149
+ var providersWithMethod, results, fulfilledResults;
150
+ return _regeneratorRuntime.wrap(function (_context5) {
151
+ while (1) switch (_context5.prev = _context5.next) {
152
+ case 0:
153
+ _context5.next = 1;
154
+ return getFulfilledProviders();
155
+ case 1:
156
+ providersWithMethod = _context5.sent.filter(function (provider) {
157
+ return typeof provider[methodName] === 'function';
158
+ });
159
+ _context5.next = 2;
160
+ return waitForAllPromises(providersWithMethod.map(createCallback(methodName, args)));
161
+ case 2:
162
+ results = _context5.sent;
163
+ fulfilledResults = getOnlyFulfilled(results);
164
+ return _context5.abrupt("return", flatten(fulfilledResults).filter(function (result) {
165
+ return result;
166
+ }));
167
+ case 3:
168
+ case "end":
169
+ return _context5.stop();
170
+ }
171
+ }, _callee5);
172
+ }));
173
+ return function invokeOptionalList(_x6, _x7) {
174
+ return _ref6.apply(this, arguments);
175
+ };
176
+ }();
144
177
  return {
145
178
  invokeSingle: invokeSingle,
146
- invokeList: invokeList
179
+ invokeList: invokeList,
180
+ invokeOptionalList: invokeOptionalList
147
181
  };
148
182
  });
@@ -0,0 +1,3 @@
1
+ export var getQuickInsertProviderMenuItemKey = function getQuickInsertProviderMenuItemKey(key) {
2
+ return "quick-insert-provider-".concat(key);
3
+ };
@@ -7,4 +7,5 @@ export var MEDIA_SECTION_RANK = _defineProperty(_defineProperty(_defineProperty(
7
7
  export var TEXT_FORMATTING_SECTION_RANK = _defineProperty(_defineProperty({}, UNORDERED_LIST_MENU_ITEM.key, 1100), ORDERED_LIST_MENU_ITEM.key, 1200);
8
8
  export var ROVO_SECTION_RANK = _defineProperty({}, ASK_ROVO_MENU_ITEM.key, 100);
9
9
  export var DATA_AND_CHARTS_SECTION_RANK = _defineProperty(_defineProperty({}, JIRA_WORK_ITEMS_MENU_ITEM.key, 300), ASSETS_MENU_ITEM.key, 500);
10
+ export var EXTENSION_ITEM_RANK = 1500;
10
11
  export var CATEGORY_VIEW_MORE_RANK = Number.MAX_SAFE_INTEGER;
@@ -21,7 +21,7 @@ import withAnalyticsEvents from '@atlaskit/analytics-next/withAnalyticsEvents';
21
21
  import { fg } from '@atlaskit/platform-feature-flags';
22
22
  import Layer from '../Layer';
23
23
  var packageName = "@atlaskit/editor-common";
24
- var packageVersion = "118.6.0";
24
+ var packageVersion = "118.8.0";
25
25
  var halfFocusRing = 1;
26
26
  var dropOffset = '0, 8';
27
27
  var fadeIn = keyframes({
@@ -254,11 +254,21 @@ export declare const aiSuggestionsMessages: {
254
254
  description: string;
255
255
  id: string;
256
256
  };
257
+ thinkingCompleteNoSuggestionsUpdated: {
258
+ defaultMessage: string;
259
+ description: string;
260
+ id: string;
261
+ };
257
262
  thinkingCompleteReviewComplete: {
258
263
  defaultMessage: string;
259
264
  description: string;
260
265
  id: string;
261
266
  };
267
+ thinkingCompleteReviewCompleteUpdated: {
268
+ defaultMessage: string;
269
+ description: string;
270
+ id: string;
271
+ };
262
272
  thinkingCompleteViewSuggestions: {
263
273
  defaultMessage: string;
264
274
  description: string;
@@ -0,0 +1,5 @@
1
+ import type { Mode } from './mode';
2
+ /**
3
+ * Check if the connectivity mode represents ANY offline state
4
+ */
5
+ export declare const isOfflineMode: (mode: Mode | undefined) => boolean;
@@ -0,0 +1 @@
1
+ export type Mode = 'offline' | 'online' | 'collab-offline' | 'internet-offline';
@@ -1,5 +1,6 @@
1
1
  import type { Node } from '@atlaskit/editor-prosemirror/model';
2
2
  import type { EditorState, Transaction } from '@atlaskit/editor-prosemirror/state';
3
+ import type { RegisterMenuItem } from '@atlaskit/editor-ui-control-model/types';
3
4
  import type { INPUT_METHOD } from '../analytics/types/enums';
4
5
  import type { TypeAheadItem } from '../types/type-ahead';
5
6
  export type QuickInsertActionInsert = (node?: Node | Record<string, any> | string, opts?: {
@@ -25,5 +26,7 @@ export type QuickInsertItem = TypeAheadItem & {
25
26
  keywords?: Array<string>;
26
27
  };
27
28
  export type QuickInsertProvider = {
29
+ /** Registered leaf items for the Quick Insert browse menu. */
30
+ getComponents?: () => Promise<Array<RegisterMenuItem>>;
28
31
  getItems: () => Promise<Array<QuickInsertItem>>;
29
32
  };
@@ -5,5 +5,6 @@ export default _default;
5
5
  */
6
6
  declare function _default<P>(providers: (P | Promise<P>)[]): {
7
7
  invokeList: <T>(methodName: keyof P, args?: any[]) => Promise<T[]>;
8
+ invokeOptionalList: <T>(methodName: keyof P, args?: any[]) => Promise<T[]>;
8
9
  invokeSingle: <T>(methodName: keyof P, args?: any[]) => Promise<T>;
9
10
  };
@@ -9,6 +9,7 @@ export type QuickInsertSelectionHandler = (context: {
9
9
  }) => Transaction | false | void;
10
10
  export type QuickInsertContextValue = {
11
11
  editorView: EditorView;
12
+ isOffline: boolean;
12
13
  item?: {
13
14
  id: string;
14
15
  isSelected: boolean;
@@ -0,0 +1 @@
1
+ export declare const getQuickInsertProviderMenuItemKey: (key: string) => string;
@@ -37,4 +37,5 @@ export declare const DATA_AND_CHARTS_SECTION_RANK: {
37
37
  readonly 'quick-insert-assets-menu-item': 500;
38
38
  readonly 'quick-insert-jira-work-items-menu-item': 300;
39
39
  };
40
+ export declare const EXTENSION_ITEM_RANK = 1500;
40
41
  export declare const CATEGORY_VIEW_MORE_RANK: number;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-common",
3
- "version": "118.7.0",
3
+ "version": "118.9.0",
4
4
  "description": "A package that contains common classes and components for editor and renderer",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -49,6 +49,7 @@
49
49
  "@atlaskit/editor-tables": "^3.0.0",
50
50
  "@atlaskit/editor-toolbar": "^2.4.0",
51
51
  "@atlaskit/editor-toolbar-model": "^1.2.0",
52
+ "@atlaskit/editor-ui-control-model": "^2.5.0",
52
53
  "@atlaskit/emoji": "^71.16.0",
53
54
  "@atlaskit/feature-gate-js-client": "^6.0.0",
54
55
  "@atlaskit/icon": "^37.3.0",
@@ -0,0 +1,10 @@
1
+ {
2
+ "name": "@atlaskit/editor-common/quick-insert/get-provider-menu-item-key",
3
+ "main": "../../dist/cjs/quick-insert/getQuickInsertProviderMenuItemKey.js",
4
+ "module": "../../dist/esm/quick-insert/getQuickInsertProviderMenuItemKey.js",
5
+ "module:es2019": "../../dist/es2019/quick-insert/getQuickInsertProviderMenuItemKey.js",
6
+ "sideEffects": [
7
+ "**/*.compiled.css"
8
+ ],
9
+ "types": "../../dist/types/quick-insert/getQuickInsertProviderMenuItemKey.d.ts"
10
+ }