@atlaskit/editor-plugin-quick-insert 18.1.1 → 19.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 +26 -0
- package/dist/cjs/quickInsertPlugin.js +1 -1
- package/dist/cjs/ui/getLegacyCompatibleComponents.js +2 -2
- package/dist/es2019/quickInsertPlugin.js +1 -1
- package/dist/es2019/ui/getLegacyCompatibleComponents.js +2 -2
- package/dist/esm/quickInsertPlugin.js +1 -1
- package/dist/esm/ui/getLegacyCompatibleComponents.js +2 -2
- package/package.json +9 -9
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,31 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-quick-insert
|
|
2
2
|
|
|
3
|
+
## 19.0.0
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies
|
|
8
|
+
|
|
9
|
+
## 18.1.2
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- [`749f1c3c8359c`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/749f1c3c8359c) -
|
|
14
|
+
Retain the first 30 category results and include the first 10 ecosystem quick-insert registrations
|
|
15
|
+
when they fall beyond that cutoff.
|
|
16
|
+
|
|
17
|
+
Limit slash-command insert-menu category browsing while preserving uncapped search results.
|
|
18
|
+
|
|
19
|
+
Classify ecosystem quick-insert provider registrations without changing compatibility keys.
|
|
20
|
+
|
|
21
|
+
Preserve app provenance for Quick Insert items while the `platform_editor_slash_command`
|
|
22
|
+
experiment is enabled.
|
|
23
|
+
|
|
24
|
+
Enable Quick Insert category analytics while the `platform_editor_slash_command` experiment is
|
|
25
|
+
enabled.
|
|
26
|
+
|
|
27
|
+
- Updated dependencies
|
|
28
|
+
|
|
3
29
|
## 18.1.1
|
|
4
30
|
|
|
5
31
|
### Patch Changes
|
|
@@ -437,7 +437,7 @@ function quickInsertPluginFactory(defaultItems, providerFactory, getIntl, dispat
|
|
|
437
437
|
provider: provider,
|
|
438
438
|
providedItems: providedItems
|
|
439
439
|
})(editorView.state, editorView.dispatch);
|
|
440
|
-
if (!isDestroyed && !quickInsertItemsAnalyticsScheduler && (0, _isExperimentEnabled.isExperimentEnabled)('platform_editor_slash_app_category_analytics')) {
|
|
440
|
+
if (!isDestroyed && !quickInsertItemsAnalyticsScheduler && ((0, _isExperimentEnabled.isExperimentEnabled)('platform_editor_slash_app_category_analytics') || (0, _isExperimentEnabled.isExperimentEnabled)('platform_editor_slash_command'))) {
|
|
441
441
|
quickInsertItemsAnalyticsScheduler = (0, _appCategoryAnalytics.createQuickInsertItemsAnalyticsScheduler)(dispatchAnalyticsEvent);
|
|
442
442
|
quickInsertItemsAnalyticsScheduler.schedule({
|
|
443
443
|
providedItems: providedItems
|
|
@@ -53,7 +53,7 @@ var getComponentsFromLegacyItems = function getComponentsFromLegacyItems(items,
|
|
|
53
53
|
var identity = getItemIdentity(item, index);
|
|
54
54
|
return {
|
|
55
55
|
type: 'menu-item',
|
|
56
|
-
key: (0, _getProviderMenuItemKey.getQuickInsertProviderMenuItemKey)(identity),
|
|
56
|
+
key: (0, _getProviderMenuItemKey.getQuickInsertProviderMenuItemKey)(identity, item.app),
|
|
57
57
|
parents: (0, _getMenuItemParents.getQuickInsertMenuItemParents)({
|
|
58
58
|
category: item.category,
|
|
59
59
|
legacyCategories: item.categories,
|
|
@@ -96,7 +96,7 @@ var getLegacyCompatibleComponents = exports.getLegacyCompatibleComponents = func
|
|
|
96
96
|
return getItemIdentity(candidate, index) === component.key;
|
|
97
97
|
});
|
|
98
98
|
return _objectSpread(_objectSpread({}, component), {}, {
|
|
99
|
-
key: (0, _getProviderMenuItemKey.getQuickInsertProviderMenuItemKey)(component.key),
|
|
99
|
+
key: (0, _getProviderMenuItemKey.getQuickInsertProviderMenuItemKey)(component.key, item === null || item === void 0 ? void 0 : item.app),
|
|
100
100
|
component: item ? function (props) {
|
|
101
101
|
return component.component(_objectSpread(_objectSpread({}, props), {}, {
|
|
102
102
|
onInsert: function onInsert() {
|
|
@@ -369,7 +369,7 @@ function quickInsertPluginFactory(defaultItems, providerFactory, getIntl, dispat
|
|
|
369
369
|
provider,
|
|
370
370
|
providedItems
|
|
371
371
|
})(editorView.state, editorView.dispatch);
|
|
372
|
-
if (!isDestroyed && !quickInsertItemsAnalyticsScheduler && isExperimentEnabled('platform_editor_slash_app_category_analytics')) {
|
|
372
|
+
if (!isDestroyed && !quickInsertItemsAnalyticsScheduler && (isExperimentEnabled('platform_editor_slash_app_category_analytics') || isExperimentEnabled('platform_editor_slash_command'))) {
|
|
373
373
|
quickInsertItemsAnalyticsScheduler = createQuickInsertItemsAnalyticsScheduler(dispatchAnalyticsEvent);
|
|
374
374
|
quickInsertItemsAnalyticsScheduler.schedule({
|
|
375
375
|
providedItems
|
|
@@ -44,7 +44,7 @@ const getComponentsFromLegacyItems = (items, onInsert) => items.map((item, index
|
|
|
44
44
|
const identity = getItemIdentity(item, index);
|
|
45
45
|
return {
|
|
46
46
|
type: 'menu-item',
|
|
47
|
-
key: getQuickInsertProviderMenuItemKey(identity),
|
|
47
|
+
key: getQuickInsertProviderMenuItemKey(identity, item.app),
|
|
48
48
|
parents: getQuickInsertMenuItemParents({
|
|
49
49
|
category: item.category,
|
|
50
50
|
legacyCategories: item.categories,
|
|
@@ -76,7 +76,7 @@ export const getLegacyCompatibleComponents = ({
|
|
|
76
76
|
const item = filteredItems.find((candidate, index) => getItemIdentity(candidate, index) === component.key);
|
|
77
77
|
return {
|
|
78
78
|
...component,
|
|
79
|
-
key: getQuickInsertProviderMenuItemKey(component.key),
|
|
79
|
+
key: getQuickInsertProviderMenuItemKey(component.key, item === null || item === void 0 ? void 0 : item.app),
|
|
80
80
|
component: item ? props => component.component({
|
|
81
81
|
...props,
|
|
82
82
|
onInsert: () => onInsert(item)
|
|
@@ -430,7 +430,7 @@ function quickInsertPluginFactory(defaultItems, providerFactory, getIntl, dispat
|
|
|
430
430
|
provider: provider,
|
|
431
431
|
providedItems: providedItems
|
|
432
432
|
})(editorView.state, editorView.dispatch);
|
|
433
|
-
if (!isDestroyed && !quickInsertItemsAnalyticsScheduler && isExperimentEnabled('platform_editor_slash_app_category_analytics')) {
|
|
433
|
+
if (!isDestroyed && !quickInsertItemsAnalyticsScheduler && (isExperimentEnabled('platform_editor_slash_app_category_analytics') || isExperimentEnabled('platform_editor_slash_command'))) {
|
|
434
434
|
quickInsertItemsAnalyticsScheduler = createQuickInsertItemsAnalyticsScheduler(dispatchAnalyticsEvent);
|
|
435
435
|
quickInsertItemsAnalyticsScheduler.schedule({
|
|
436
436
|
providedItems: providedItems
|
|
@@ -46,7 +46,7 @@ var getComponentsFromLegacyItems = function getComponentsFromLegacyItems(items,
|
|
|
46
46
|
var identity = getItemIdentity(item, index);
|
|
47
47
|
return {
|
|
48
48
|
type: 'menu-item',
|
|
49
|
-
key: getQuickInsertProviderMenuItemKey(identity),
|
|
49
|
+
key: getQuickInsertProviderMenuItemKey(identity, item.app),
|
|
50
50
|
parents: getQuickInsertMenuItemParents({
|
|
51
51
|
category: item.category,
|
|
52
52
|
legacyCategories: item.categories,
|
|
@@ -89,7 +89,7 @@ export var getLegacyCompatibleComponents = function getLegacyCompatibleComponent
|
|
|
89
89
|
return getItemIdentity(candidate, index) === component.key;
|
|
90
90
|
});
|
|
91
91
|
return _objectSpread(_objectSpread({}, component), {}, {
|
|
92
|
-
key: getQuickInsertProviderMenuItemKey(component.key),
|
|
92
|
+
key: getQuickInsertProviderMenuItemKey(component.key, item === null || item === void 0 ? void 0 : item.app),
|
|
93
93
|
component: item ? function (props) {
|
|
94
94
|
return component.component(_objectSpread(_objectSpread({}, props), {}, {
|
|
95
95
|
onInsert: function onInsert() {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-quick-insert",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "19.0.0",
|
|
4
4
|
"description": "Quick insert plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -28,12 +28,12 @@
|
|
|
28
28
|
"dependencies": {
|
|
29
29
|
"@atlaskit/button": "^25.3.0",
|
|
30
30
|
"@atlaskit/css": "^1.1.0",
|
|
31
|
-
"@atlaskit/editor-plugin-analytics": "^
|
|
32
|
-
"@atlaskit/editor-plugin-connectivity": "^
|
|
33
|
-
"@atlaskit/editor-plugin-metrics": "^
|
|
34
|
-
"@atlaskit/editor-plugin-type-ahead": "^
|
|
35
|
-
"@atlaskit/editor-plugin-ui-control-registry": "^
|
|
36
|
-
"@atlaskit/editor-prosemirror": "^
|
|
31
|
+
"@atlaskit/editor-plugin-analytics": "^19.0.0",
|
|
32
|
+
"@atlaskit/editor-plugin-connectivity": "^19.0.0",
|
|
33
|
+
"@atlaskit/editor-plugin-metrics": "^20.0.0",
|
|
34
|
+
"@atlaskit/editor-plugin-type-ahead": "^20.0.0",
|
|
35
|
+
"@atlaskit/editor-plugin-ui-control-registry": "^13.0.0",
|
|
36
|
+
"@atlaskit/editor-prosemirror": "^9.0.0",
|
|
37
37
|
"@atlaskit/editor-tables": "^3.2.0",
|
|
38
38
|
"@atlaskit/editor-ui-control-model": "^2.9.0",
|
|
39
39
|
"@atlaskit/heading": "^7.2.0",
|
|
@@ -44,14 +44,14 @@
|
|
|
44
44
|
"@atlaskit/primitives": "^22.5.0",
|
|
45
45
|
"@atlaskit/textfield": "^10.2.0",
|
|
46
46
|
"@atlaskit/tmp-editor-statsig": "^199.0.0",
|
|
47
|
-
"@atlaskit/tokens": "^18.
|
|
47
|
+
"@atlaskit/tokens": "^18.2.0",
|
|
48
48
|
"@atlaskit/tooltip": "^24.3.0",
|
|
49
49
|
"@babel/runtime": "^7.0.0",
|
|
50
50
|
"@compiled/react": "^1.0.2",
|
|
51
51
|
"@emotion/react": "^11.7.1"
|
|
52
52
|
},
|
|
53
53
|
"peerDependencies": {
|
|
54
|
-
"@atlaskit/editor-common": "^
|
|
54
|
+
"@atlaskit/editor-common": "^123.0.0",
|
|
55
55
|
"react": "^18.2.0 || ^19.2.0",
|
|
56
56
|
"react-dom": "^18.2.0 || ^19.2.0",
|
|
57
57
|
"react-intl": "^5.25.1 || ^6.0.0 || ^7.0.0"
|