@atlaskit/editor-plugin-quick-insert 16.2.3 → 16.2.5
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 +17 -0
- package/dist/cjs/app-category-analytics.js +4 -3
- package/dist/cjs/quickInsertPlugin.js +2 -2
- package/dist/cjs/ui/BlockControlQuickInsertButton.compiled.css +2 -0
- package/dist/cjs/ui/BlockControlQuickInsertButton.js +1 -1
- package/dist/cjs/ui/getLegacyCompatibleComponents.js +2 -1
- package/dist/cjs/ui/search.js +2 -1
- package/dist/es2019/app-category-analytics.js +4 -3
- package/dist/es2019/quickInsertPlugin.js +2 -4
- package/dist/es2019/ui/BlockControlQuickInsertButton.compiled.css +2 -0
- package/dist/es2019/ui/BlockControlQuickInsertButton.js +1 -1
- package/dist/es2019/ui/getLegacyCompatibleComponents.js +2 -1
- package/dist/es2019/ui/search.js +2 -1
- package/dist/esm/app-category-analytics.js +4 -3
- package/dist/esm/quickInsertPlugin.js +2 -2
- package/dist/esm/ui/BlockControlQuickInsertButton.compiled.css +2 -0
- package/dist/esm/ui/BlockControlQuickInsertButton.js +1 -1
- package/dist/esm/ui/getLegacyCompatibleComponents.js +2 -1
- package/dist/esm/ui/search.js +2 -1
- package/package.json +3 -39
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,22 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-quick-insert
|
|
2
2
|
|
|
3
|
+
## 16.2.5
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`bcfe498b206d5`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/bcfe498b206d5) -
|
|
8
|
+
Adopt button and list-item motion tokens behind the use-pressable-motion rollout.
|
|
9
|
+
- Updated dependencies
|
|
10
|
+
|
|
11
|
+
## 16.2.4
|
|
12
|
+
|
|
13
|
+
### Patch Changes
|
|
14
|
+
|
|
15
|
+
- [`25ed290dcc443`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/25ed290dcc443) -
|
|
16
|
+
Add Quick Insert category selection support for slash commands behind the
|
|
17
|
+
platform_editor_slash_command feature flag.
|
|
18
|
+
- Updated dependencies
|
|
19
|
+
|
|
3
20
|
## 16.2.3
|
|
4
21
|
|
|
5
22
|
### Patch Changes
|
|
@@ -118,9 +118,9 @@ var calculateQuickInsertItemsAttributes = exports.calculateQuickInsertItemsAttri
|
|
|
118
118
|
}
|
|
119
119
|
};
|
|
120
120
|
var countItem = function countItem(item) {
|
|
121
|
-
var _categories$map$filte;
|
|
121
|
+
var _item$categories, _categories$map$filte;
|
|
122
122
|
countCategoryItem(attributes.allCategories, item);
|
|
123
|
-
var categories = item.categories;
|
|
123
|
+
var categories = (_item$categories = item.categories) !== null && _item$categories !== void 0 ? _item$categories : [];
|
|
124
124
|
var normalizedCategories = new Set((_categories$map$filte = categories === null || categories === void 0 ? void 0 : categories.map(function (category) {
|
|
125
125
|
return category.trim().toLowerCase();
|
|
126
126
|
}).filter(Boolean)) !== null && _categories$map$filte !== void 0 ? _categories$map$filte : []);
|
|
@@ -145,7 +145,8 @@ var calculateQuickInsertItemsAttributes = exports.calculateQuickInsertItemsAttri
|
|
|
145
145
|
countCategoryItem(attributes.legacyCategory.uncategorized, item);
|
|
146
146
|
}
|
|
147
147
|
var _iterator2 = _createForOfIteratorHelper((0, _getMenuItemParents.getQuickInsertMenuItemParents)({
|
|
148
|
-
|
|
148
|
+
category: item.category,
|
|
149
|
+
legacyCategories: item.categories,
|
|
149
150
|
rank: 0
|
|
150
151
|
})),
|
|
151
152
|
_step2;
|
|
@@ -14,6 +14,7 @@ var _reactIntl = require("react-intl");
|
|
|
14
14
|
var _coreUtils = require("@atlaskit/editor-common/core-utils");
|
|
15
15
|
var _messages = require("@atlaskit/editor-common/messages");
|
|
16
16
|
var _quickInsert = require("@atlaskit/editor-common/quick-insert");
|
|
17
|
+
var _getActiveQuickInsertCategories = require("@atlaskit/editor-common/quick-insert/get-active-quick-insert-categories");
|
|
17
18
|
var _safePlugin = require("@atlaskit/editor-common/safe-plugin");
|
|
18
19
|
var _typeAhead = require("@atlaskit/editor-common/type-ahead");
|
|
19
20
|
var _showMoreHorizontal = _interopRequireDefault(require("@atlaskit/icon/core/show-more-horizontal"));
|
|
@@ -71,8 +72,7 @@ var quickInsertPlugin = exports.quickInsertPlugin = function quickInsertPlugin(_
|
|
|
71
72
|
disableDefaultItems: options === null || options === void 0 ? void 0 : options.disableDefaultItems,
|
|
72
73
|
prioritySortingFn: options === null || options === void 0 ? void 0 : options.prioritySortingFn,
|
|
73
74
|
itemFilter: function itemFilter(item) {
|
|
74
|
-
|
|
75
|
-
return (_item$categories$incl = (_item$categories = item.categories) === null || _item$categories === void 0 ? void 0 : _item$categories.includes('AI')) !== null && _item$categories$incl !== void 0 ? _item$categories$incl : false;
|
|
75
|
+
return (0, _getActiveQuickInsertCategories.getActiveQuickInsertCategories)(item.category, item.categories).includes('AI');
|
|
76
76
|
}
|
|
77
77
|
}, quickInsertState === null || quickInsertState === void 0 ? void 0 : quickInsertState.lazyDefaultItems, quickInsertState === null || quickInsertState === void 0 ? void 0 : quickInsertState.providedItems);
|
|
78
78
|
return matches[0];
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
._19itglyw{border:none}
|
|
2
2
|
._2rko1rr0{border-radius:var(--ds-radius-full,9999px)}
|
|
3
|
+
._v564k6bl{transition:var(--ds-button-hovered,background-color border-color .15s cubic-bezier(.4,1,.6,1))}
|
|
3
4
|
._18zrze3t{padding-inline:var(--ds-space-0,0)}
|
|
4
5
|
._1rjcze3t{padding-block:var(--ds-space-0,0)}
|
|
5
6
|
._1bah1h6o{justify-content:center}
|
|
@@ -17,4 +18,5 @@
|
|
|
17
18
|
._mizu1v1w:focus-visible{outline-color:var(--ds-border-focused,#4688ec)}
|
|
18
19
|
._ra3xnqa1:focus-visible{outline-style:solid}
|
|
19
20
|
._irr31dpa:hover{background-color:var(--ds-background-neutral-subtle-hovered,#0515240f)}
|
|
21
|
+
._1ggl5xtf:active{transition:var(--ds-button-pressed,background-color border-color .15s cubic-bezier(.4,1,.6,1))}
|
|
20
22
|
._1di6fcek:active{background-color:var(--ds-background-neutral-subtle-pressed,#0b120e24)}
|
|
@@ -28,7 +28,7 @@ var quickInsertButtonContainerStyles = {
|
|
|
28
28
|
root: "_1e0c1txw _4t3i9xsi _1bsb9xsi"
|
|
29
29
|
};
|
|
30
30
|
var quickInsertButtonStyles = {
|
|
31
|
-
root: "_19itglyw _2rko1rr0 _1rjcze3t _18zrze3t _4cvr1h6o _bfhksm61 _vchhusvi _syazazsu _80omtlke _1e0c1txw _4t3i1osq _1bah1h6o _1bsb1osq _mizu1v1w _1ah3v77o _ra3xnqa1 _128mdkaa _irr31dpa _1di6fcek"
|
|
31
|
+
root: "_19itglyw _2rko1rr0 _v564k6bl _1rjcze3t _18zrze3t _4cvr1h6o _bfhksm61 _vchhusvi _syazazsu _80omtlke _1e0c1txw _4t3i1osq _1bah1h6o _1bsb1osq _mizu1v1w _1ah3v77o _ra3xnqa1 _128mdkaa _irr31dpa _1ggl5xtf _1di6fcek"
|
|
32
32
|
};
|
|
33
33
|
var createNewLine = function createNewLine(start) {
|
|
34
34
|
return function (_ref) {
|
|
@@ -55,7 +55,8 @@ var getComponentsFromLegacyItems = function getComponentsFromLegacyItems(items,
|
|
|
55
55
|
type: 'menu-item',
|
|
56
56
|
key: (0, _getProviderMenuItemKey.getQuickInsertProviderMenuItemKey)(identity),
|
|
57
57
|
parents: (0, _getMenuItemParents.getQuickInsertMenuItemParents)({
|
|
58
|
-
|
|
58
|
+
category: item.category,
|
|
59
|
+
legacyCategories: item.categories,
|
|
59
60
|
rank: (_item$priority = item.priority) !== null && _item$priority !== void 0 ? _item$priority : index
|
|
60
61
|
}),
|
|
61
62
|
component: function component() {
|
package/dist/cjs/ui/search.js
CHANGED
|
@@ -7,6 +7,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
7
7
|
exports.withLayoutQuickInsertPrioritySorting = exports.getQuickInsertSuggestions = void 0;
|
|
8
8
|
var _toConsumableArray2 = _interopRequireDefault(require("@babel/runtime/helpers/toConsumableArray"));
|
|
9
9
|
var _quickInsert = require("@atlaskit/editor-common/quick-insert");
|
|
10
|
+
var _getActiveQuickInsertCategories = require("@atlaskit/editor-common/quick-insert/get-active-quick-insert-categories");
|
|
10
11
|
var _utils = require("@atlaskit/editor-common/utils");
|
|
11
12
|
var _fg = require("@atlaskit/platform-feature-flags/fg");
|
|
12
13
|
var isRegisteredLayoutQuickInsertItem = function isRegisteredLayoutQuickInsertItem(item) {
|
|
@@ -70,6 +71,6 @@ var getQuickInsertSuggestions = exports.getQuickInsertSuggestions = function get
|
|
|
70
71
|
});
|
|
71
72
|
}
|
|
72
73
|
return (0, _quickInsert.find)(((0, _fg.fg)('platform_editor_fix_space_triggering_ai') ? query === null || query === void 0 ? void 0 : query.trimEnd() : query) || '', category === 'all' || !category ? items : items.filter(function (item) {
|
|
73
|
-
return item.
|
|
74
|
+
return (0, _getActiveQuickInsertCategories.getActiveQuickInsertCategories)(item.category, item.categories).includes(category);
|
|
74
75
|
}), prioritySortingFn);
|
|
75
76
|
};
|
|
@@ -111,9 +111,9 @@ export const calculateQuickInsertItemsAttributes = ({
|
|
|
111
111
|
}
|
|
112
112
|
};
|
|
113
113
|
const countItem = item => {
|
|
114
|
-
var _categories$map$filte;
|
|
114
|
+
var _item$categories, _categories$map$filte;
|
|
115
115
|
countCategoryItem(attributes.allCategories, item);
|
|
116
|
-
const categories = item.categories;
|
|
116
|
+
const categories = (_item$categories = item.categories) !== null && _item$categories !== void 0 ? _item$categories : [];
|
|
117
117
|
const normalizedCategories = new Set((_categories$map$filte = categories === null || categories === void 0 ? void 0 : categories.map(category => category.trim().toLowerCase()).filter(Boolean)) !== null && _categories$map$filte !== void 0 ? _categories$map$filte : []);
|
|
118
118
|
let hasUnknownCategory = normalizedCategories.size === 0;
|
|
119
119
|
for (const category of normalizedCategories) {
|
|
@@ -129,7 +129,8 @@ export const calculateQuickInsertItemsAttributes = ({
|
|
|
129
129
|
for (const {
|
|
130
130
|
key
|
|
131
131
|
} of getQuickInsertMenuItemParents({
|
|
132
|
-
|
|
132
|
+
category: item.category,
|
|
133
|
+
legacyCategories: item.categories,
|
|
133
134
|
rank: 0
|
|
134
135
|
})) {
|
|
135
136
|
const categoryKey = sectionCategoryKeys[key];
|
|
@@ -3,6 +3,7 @@ import { useIntl } from 'react-intl';
|
|
|
3
3
|
import { isSSR } from '@atlaskit/editor-common/core-utils';
|
|
4
4
|
import { toolbarInsertBlockMessages as messages } from '@atlaskit/editor-common/messages';
|
|
5
5
|
import { memoProcessQuickInsertItems } from '@atlaskit/editor-common/quick-insert';
|
|
6
|
+
import { getActiveQuickInsertCategories } from '@atlaskit/editor-common/quick-insert/get-active-quick-insert-categories';
|
|
6
7
|
import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
|
|
7
8
|
import { TypeAheadAvailableNodes } from '@atlaskit/editor-common/type-ahead';
|
|
8
9
|
import ShowMoreHorizontalIcon from '@atlaskit/icon/core/show-more-horizontal';
|
|
@@ -60,10 +61,7 @@ export const quickInsertPlugin = ({
|
|
|
60
61
|
query: '',
|
|
61
62
|
disableDefaultItems: options === null || options === void 0 ? void 0 : options.disableDefaultItems,
|
|
62
63
|
prioritySortingFn: options === null || options === void 0 ? void 0 : options.prioritySortingFn,
|
|
63
|
-
itemFilter: item =>
|
|
64
|
-
var _item$categories$incl, _item$categories;
|
|
65
|
-
return (_item$categories$incl = (_item$categories = item.categories) === null || _item$categories === void 0 ? void 0 : _item$categories.includes('AI')) !== null && _item$categories$incl !== void 0 ? _item$categories$incl : false;
|
|
66
|
-
}
|
|
64
|
+
itemFilter: item => getActiveQuickInsertCategories(item.category, item.categories).includes('AI')
|
|
67
65
|
}, quickInsertState === null || quickInsertState === void 0 ? void 0 : quickInsertState.lazyDefaultItems, quickInsertState === null || quickInsertState === void 0 ? void 0 : quickInsertState.providedItems);
|
|
68
66
|
return matches[0];
|
|
69
67
|
},
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
._19itglyw{border:none}
|
|
2
2
|
._2rko1rr0{border-radius:var(--ds-radius-full,9999px)}
|
|
3
|
+
._v564k6bl{transition:var(--ds-button-hovered,background-color border-color .15s cubic-bezier(.4,1,.6,1))}
|
|
3
4
|
._18zrze3t{padding-inline:var(--ds-space-0,0)}
|
|
4
5
|
._1rjcze3t{padding-block:var(--ds-space-0,0)}
|
|
5
6
|
._1bah1h6o{justify-content:center}
|
|
@@ -17,4 +18,5 @@
|
|
|
17
18
|
._mizu1v1w:focus-visible{outline-color:var(--ds-border-focused,#4688ec)}
|
|
18
19
|
._ra3xnqa1:focus-visible{outline-style:solid}
|
|
19
20
|
._irr31dpa:hover{background-color:var(--ds-background-neutral-subtle-hovered,#0515240f)}
|
|
21
|
+
._1ggl5xtf:active{transition:var(--ds-button-pressed,background-color border-color .15s cubic-bezier(.4,1,.6,1))}
|
|
20
22
|
._1di6fcek:active{background-color:var(--ds-background-neutral-subtle-pressed,#0b120e24)}
|
|
@@ -19,7 +19,7 @@ const quickInsertButtonContainerStyles = {
|
|
|
19
19
|
root: "_1e0c1txw _4t3i9xsi _1bsb9xsi"
|
|
20
20
|
};
|
|
21
21
|
const quickInsertButtonStyles = {
|
|
22
|
-
root: "_19itglyw _2rko1rr0 _1rjcze3t _18zrze3t _4cvr1h6o _bfhksm61 _vchhusvi _syazazsu _80omtlke _1e0c1txw _4t3i1osq _1bah1h6o _1bsb1osq _mizu1v1w _1ah3v77o _ra3xnqa1 _128mdkaa _irr31dpa _1di6fcek"
|
|
22
|
+
root: "_19itglyw _2rko1rr0 _v564k6bl _1rjcze3t _18zrze3t _4cvr1h6o _bfhksm61 _vchhusvi _syazazsu _80omtlke _1e0c1txw _4t3i1osq _1bah1h6o _1bsb1osq _mizu1v1w _1ah3v77o _ra3xnqa1 _128mdkaa _irr31dpa _1ggl5xtf _1di6fcek"
|
|
23
23
|
};
|
|
24
24
|
const createNewLine = start => ({
|
|
25
25
|
tr
|
|
@@ -46,7 +46,8 @@ const getComponentsFromLegacyItems = (items, onInsert) => items.map((item, index
|
|
|
46
46
|
type: 'menu-item',
|
|
47
47
|
key: getQuickInsertProviderMenuItemKey(identity),
|
|
48
48
|
parents: getQuickInsertMenuItemParents({
|
|
49
|
-
|
|
49
|
+
category: item.category,
|
|
50
|
+
legacyCategories: item.categories,
|
|
50
51
|
rank: (_item$priority = item.priority) !== null && _item$priority !== void 0 ? _item$priority : index
|
|
51
52
|
}),
|
|
52
53
|
component: () => /*#__PURE__*/React.createElement(LegacyQuickInsertProviderMenuItem, {
|
package/dist/es2019/ui/search.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { find } from '@atlaskit/editor-common/quick-insert';
|
|
2
|
+
import { getActiveQuickInsertCategories } from '@atlaskit/editor-common/quick-insert/get-active-quick-insert-categories';
|
|
2
3
|
import { dedupe } from '@atlaskit/editor-common/utils';
|
|
3
4
|
import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
4
5
|
const isRegisteredLayoutQuickInsertItem = item => {
|
|
@@ -51,5 +52,5 @@ export const getQuickInsertSuggestions = (searchOptions, lazyDefaultItems = () =
|
|
|
51
52
|
if (featuredItems) {
|
|
52
53
|
return items.filter(item => item.featured);
|
|
53
54
|
}
|
|
54
|
-
return find((fg('platform_editor_fix_space_triggering_ai') ? query === null || query === void 0 ? void 0 : query.trimEnd() : query) || '', category === 'all' || !category ? items : items.filter(item => item.
|
|
55
|
+
return find((fg('platform_editor_fix_space_triggering_ai') ? query === null || query === void 0 ? void 0 : query.trimEnd() : query) || '', category === 'all' || !category ? items : items.filter(item => getActiveQuickInsertCategories(item.category, item.categories).includes(category)), prioritySortingFn);
|
|
55
56
|
};
|
|
@@ -111,9 +111,9 @@ export var calculateQuickInsertItemsAttributes = function calculateQuickInsertIt
|
|
|
111
111
|
}
|
|
112
112
|
};
|
|
113
113
|
var countItem = function countItem(item) {
|
|
114
|
-
var _categories$map$filte;
|
|
114
|
+
var _item$categories, _categories$map$filte;
|
|
115
115
|
countCategoryItem(attributes.allCategories, item);
|
|
116
|
-
var categories = item.categories;
|
|
116
|
+
var categories = (_item$categories = item.categories) !== null && _item$categories !== void 0 ? _item$categories : [];
|
|
117
117
|
var normalizedCategories = new Set((_categories$map$filte = categories === null || categories === void 0 ? void 0 : categories.map(function (category) {
|
|
118
118
|
return category.trim().toLowerCase();
|
|
119
119
|
}).filter(Boolean)) !== null && _categories$map$filte !== void 0 ? _categories$map$filte : []);
|
|
@@ -138,7 +138,8 @@ export var calculateQuickInsertItemsAttributes = function calculateQuickInsertIt
|
|
|
138
138
|
countCategoryItem(attributes.legacyCategory.uncategorized, item);
|
|
139
139
|
}
|
|
140
140
|
var _iterator2 = _createForOfIteratorHelper(getQuickInsertMenuItemParents({
|
|
141
|
-
|
|
141
|
+
category: item.category,
|
|
142
|
+
legacyCategories: item.categories,
|
|
142
143
|
rank: 0
|
|
143
144
|
})),
|
|
144
145
|
_step2;
|
|
@@ -9,6 +9,7 @@ import { useIntl } from 'react-intl';
|
|
|
9
9
|
import { isSSR } from '@atlaskit/editor-common/core-utils';
|
|
10
10
|
import { toolbarInsertBlockMessages as messages } from '@atlaskit/editor-common/messages';
|
|
11
11
|
import { memoProcessQuickInsertItems } from '@atlaskit/editor-common/quick-insert';
|
|
12
|
+
import { getActiveQuickInsertCategories } from '@atlaskit/editor-common/quick-insert/get-active-quick-insert-categories';
|
|
12
13
|
import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
|
|
13
14
|
import { TypeAheadAvailableNodes } from '@atlaskit/editor-common/type-ahead';
|
|
14
15
|
import ShowMoreHorizontalIcon from '@atlaskit/icon/core/show-more-horizontal';
|
|
@@ -64,8 +65,7 @@ export var quickInsertPlugin = function quickInsertPlugin(_ref) {
|
|
|
64
65
|
disableDefaultItems: options === null || options === void 0 ? void 0 : options.disableDefaultItems,
|
|
65
66
|
prioritySortingFn: options === null || options === void 0 ? void 0 : options.prioritySortingFn,
|
|
66
67
|
itemFilter: function itemFilter(item) {
|
|
67
|
-
|
|
68
|
-
return (_item$categories$incl = (_item$categories = item.categories) === null || _item$categories === void 0 ? void 0 : _item$categories.includes('AI')) !== null && _item$categories$incl !== void 0 ? _item$categories$incl : false;
|
|
68
|
+
return getActiveQuickInsertCategories(item.category, item.categories).includes('AI');
|
|
69
69
|
}
|
|
70
70
|
}, quickInsertState === null || quickInsertState === void 0 ? void 0 : quickInsertState.lazyDefaultItems, quickInsertState === null || quickInsertState === void 0 ? void 0 : quickInsertState.providedItems);
|
|
71
71
|
return matches[0];
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
._19itglyw{border:none}
|
|
2
2
|
._2rko1rr0{border-radius:var(--ds-radius-full,9999px)}
|
|
3
|
+
._v564k6bl{transition:var(--ds-button-hovered,background-color border-color .15s cubic-bezier(.4,1,.6,1))}
|
|
3
4
|
._18zrze3t{padding-inline:var(--ds-space-0,0)}
|
|
4
5
|
._1rjcze3t{padding-block:var(--ds-space-0,0)}
|
|
5
6
|
._1bah1h6o{justify-content:center}
|
|
@@ -17,4 +18,5 @@
|
|
|
17
18
|
._mizu1v1w:focus-visible{outline-color:var(--ds-border-focused,#4688ec)}
|
|
18
19
|
._ra3xnqa1:focus-visible{outline-style:solid}
|
|
19
20
|
._irr31dpa:hover{background-color:var(--ds-background-neutral-subtle-hovered,#0515240f)}
|
|
21
|
+
._1ggl5xtf:active{transition:var(--ds-button-pressed,background-color border-color .15s cubic-bezier(.4,1,.6,1))}
|
|
20
22
|
._1di6fcek:active{background-color:var(--ds-background-neutral-subtle-pressed,#0b120e24)}
|
|
@@ -19,7 +19,7 @@ var quickInsertButtonContainerStyles = {
|
|
|
19
19
|
root: "_1e0c1txw _4t3i9xsi _1bsb9xsi"
|
|
20
20
|
};
|
|
21
21
|
var quickInsertButtonStyles = {
|
|
22
|
-
root: "_19itglyw _2rko1rr0 _1rjcze3t _18zrze3t _4cvr1h6o _bfhksm61 _vchhusvi _syazazsu _80omtlke _1e0c1txw _4t3i1osq _1bah1h6o _1bsb1osq _mizu1v1w _1ah3v77o _ra3xnqa1 _128mdkaa _irr31dpa _1di6fcek"
|
|
22
|
+
root: "_19itglyw _2rko1rr0 _v564k6bl _1rjcze3t _18zrze3t _4cvr1h6o _bfhksm61 _vchhusvi _syazazsu _80omtlke _1e0c1txw _4t3i1osq _1bah1h6o _1bsb1osq _mizu1v1w _1ah3v77o _ra3xnqa1 _128mdkaa _irr31dpa _1ggl5xtf _1di6fcek"
|
|
23
23
|
};
|
|
24
24
|
var createNewLine = function createNewLine(start) {
|
|
25
25
|
return function (_ref) {
|
|
@@ -48,7 +48,8 @@ var getComponentsFromLegacyItems = function getComponentsFromLegacyItems(items,
|
|
|
48
48
|
type: 'menu-item',
|
|
49
49
|
key: getQuickInsertProviderMenuItemKey(identity),
|
|
50
50
|
parents: getQuickInsertMenuItemParents({
|
|
51
|
-
|
|
51
|
+
category: item.category,
|
|
52
|
+
legacyCategories: item.categories,
|
|
52
53
|
rank: (_item$priority = item.priority) !== null && _item$priority !== void 0 ? _item$priority : index
|
|
53
54
|
}),
|
|
54
55
|
component: function component() {
|
package/dist/esm/ui/search.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import _toConsumableArray from "@babel/runtime/helpers/toConsumableArray";
|
|
2
2
|
import { find } from '@atlaskit/editor-common/quick-insert';
|
|
3
|
+
import { getActiveQuickInsertCategories } from '@atlaskit/editor-common/quick-insert/get-active-quick-insert-categories';
|
|
3
4
|
import { dedupe } from '@atlaskit/editor-common/utils';
|
|
4
5
|
import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
5
6
|
var isRegisteredLayoutQuickInsertItem = function isRegisteredLayoutQuickInsertItem(item) {
|
|
@@ -63,6 +64,6 @@ export var getQuickInsertSuggestions = function getQuickInsertSuggestions(search
|
|
|
63
64
|
});
|
|
64
65
|
}
|
|
65
66
|
return find((fg('platform_editor_fix_space_triggering_ai') ? query === null || query === void 0 ? void 0 : query.trimEnd() : query) || '', category === 'all' || !category ? items : items.filter(function (item) {
|
|
66
|
-
return item.
|
|
67
|
+
return getActiveQuickInsertCategories(item.category, item.categories).includes(category);
|
|
67
68
|
}), prioritySortingFn);
|
|
68
69
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-quick-insert",
|
|
3
|
-
"version": "16.2.
|
|
3
|
+
"version": "16.2.5",
|
|
4
4
|
"description": "Quick insert plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
"@atlaskit/platform-feature-flags": "^2.2.0",
|
|
39
39
|
"@atlaskit/primitives": "^22.5.0",
|
|
40
40
|
"@atlaskit/textfield": "^10.2.0",
|
|
41
|
-
"@atlaskit/tmp-editor-statsig": "^
|
|
41
|
+
"@atlaskit/tmp-editor-statsig": "^172.0.0",
|
|
42
42
|
"@atlaskit/tokens": "^16.11.0",
|
|
43
43
|
"@atlaskit/tooltip": "^24.3.0",
|
|
44
44
|
"@babel/runtime": "^7.0.0",
|
|
@@ -46,7 +46,7 @@
|
|
|
46
46
|
"@emotion/react": "^11.7.1"
|
|
47
47
|
},
|
|
48
48
|
"peerDependencies": {
|
|
49
|
-
"@atlaskit/editor-common": "^120.
|
|
49
|
+
"@atlaskit/editor-common": "^120.11.0",
|
|
50
50
|
"react": "^18.2.0 || ^19.2.0",
|
|
51
51
|
"react-dom": "^18.2.0 || ^19.2.0",
|
|
52
52
|
"react-intl": "^5.25.1 || ^6.0.0 || ^7.0.0"
|
|
@@ -59,42 +59,6 @@
|
|
|
59
59
|
"react-intl": "^7.0.0",
|
|
60
60
|
"wait-for-expect": "^1.2.0"
|
|
61
61
|
},
|
|
62
|
-
"techstack": {
|
|
63
|
-
"@atlassian/frontend": {
|
|
64
|
-
"code-structure": [
|
|
65
|
-
"editor-plugin"
|
|
66
|
-
],
|
|
67
|
-
"import-structure": [
|
|
68
|
-
"atlassian-conventions"
|
|
69
|
-
],
|
|
70
|
-
"circular-dependencies": [
|
|
71
|
-
"file-and-folder-level"
|
|
72
|
-
]
|
|
73
|
-
},
|
|
74
|
-
"@repo/internal": {
|
|
75
|
-
"dom-events": "use-bind-event-listener",
|
|
76
|
-
"analytics": [
|
|
77
|
-
"analytics-next"
|
|
78
|
-
],
|
|
79
|
-
"design-tokens": [
|
|
80
|
-
"color"
|
|
81
|
-
],
|
|
82
|
-
"theming": [
|
|
83
|
-
"react-context"
|
|
84
|
-
],
|
|
85
|
-
"ui-components": [
|
|
86
|
-
"lite-mode"
|
|
87
|
-
],
|
|
88
|
-
"deprecation": "no-deprecated-imports",
|
|
89
|
-
"styling": [
|
|
90
|
-
"emotion",
|
|
91
|
-
"emotion"
|
|
92
|
-
],
|
|
93
|
-
"imports": [
|
|
94
|
-
"import-no-extraneous-disable-for-examples-and-docs"
|
|
95
|
-
]
|
|
96
|
-
}
|
|
97
|
-
},
|
|
98
62
|
"platform-feature-flags": {
|
|
99
63
|
"platform_editor_ease_of_use_metrics": {
|
|
100
64
|
"type": "boolean"
|