@atlaskit/editor-common 84.2.0 → 84.3.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 (70) hide show
  1. package/CHANGELOG.md +23 -0
  2. package/afm-jira/tsconfig.json +3 -0
  3. package/dist/cjs/element-browser/components/CategoryList.js +5 -18
  4. package/dist/cjs/element-browser/components/ElementList/ElementList.js +5 -5
  5. package/dist/cjs/element-browser/components/StatelessElementBrowser.js +20 -31
  6. package/dist/cjs/element-browser/hooks/use-select-and-focus-on-arrow-navigation.js +8 -17
  7. package/dist/cjs/extensibility/ExtensionNodeWrapper.js +2 -2
  8. package/dist/cjs/mark/commands.js +2 -7
  9. package/dist/cjs/messages/annotation.js +1 -1
  10. package/dist/cjs/monitoring/error.js +1 -1
  11. package/dist/cjs/react-node-view/getInlineNodeViewProducer.js +3 -2
  12. package/dist/cjs/styles/shared/annotation.js +2 -34
  13. package/dist/cjs/styles/shared/smartCard.js +1 -1
  14. package/dist/cjs/ui/DropList/index.js +1 -1
  15. package/dist/cjs/utils/annotation/index.js +10 -18
  16. package/dist/cjs/utils/index.js +5 -1
  17. package/dist/cjs/utils/scroll-gutter.js +3 -0
  18. package/dist/cjs/utils/validator.js +5 -5
  19. package/dist/cjs/whitespace/index.js +18 -0
  20. package/dist/es2019/element-browser/components/CategoryList.js +5 -14
  21. package/dist/es2019/element-browser/components/ElementList/ElementList.js +6 -6
  22. package/dist/es2019/element-browser/components/StatelessElementBrowser.js +20 -31
  23. package/dist/es2019/element-browser/hooks/use-select-and-focus-on-arrow-navigation.js +8 -17
  24. package/dist/es2019/extensibility/ExtensionNodeWrapper.js +1 -1
  25. package/dist/es2019/mark/commands.js +3 -10
  26. package/dist/es2019/messages/annotation.js +1 -1
  27. package/dist/es2019/monitoring/error.js +1 -1
  28. package/dist/es2019/react-node-view/getInlineNodeViewProducer.js +2 -1
  29. package/dist/es2019/styles/shared/annotation.js +3 -35
  30. package/dist/es2019/styles/shared/smartCard.js +2 -2
  31. package/dist/es2019/ui/DropList/index.js +1 -1
  32. package/dist/es2019/utils/annotation/index.js +11 -21
  33. package/dist/es2019/utils/index.js +4 -1
  34. package/dist/es2019/utils/scroll-gutter.js +3 -0
  35. package/dist/es2019/utils/validator.js +6 -6
  36. package/dist/es2019/whitespace/index.js +1 -0
  37. package/dist/esm/element-browser/components/CategoryList.js +5 -18
  38. package/dist/esm/element-browser/components/ElementList/ElementList.js +6 -6
  39. package/dist/esm/element-browser/components/StatelessElementBrowser.js +20 -31
  40. package/dist/esm/element-browser/hooks/use-select-and-focus-on-arrow-navigation.js +8 -17
  41. package/dist/esm/extensibility/ExtensionNodeWrapper.js +1 -1
  42. package/dist/esm/mark/commands.js +3 -8
  43. package/dist/esm/messages/annotation.js +1 -1
  44. package/dist/esm/monitoring/error.js +1 -1
  45. package/dist/esm/react-node-view/getInlineNodeViewProducer.js +2 -1
  46. package/dist/esm/styles/shared/annotation.js +3 -35
  47. package/dist/esm/styles/shared/smartCard.js +2 -2
  48. package/dist/esm/ui/DropList/index.js +1 -1
  49. package/dist/esm/utils/annotation/index.js +11 -19
  50. package/dist/esm/utils/index.js +4 -1
  51. package/dist/esm/utils/scroll-gutter.js +3 -0
  52. package/dist/esm/utils/validator.js +6 -6
  53. package/dist/esm/whitespace/index.js +1 -0
  54. package/dist/types/types/annotation/index.d.ts +2 -2
  55. package/dist/types/utils/annotation/index.d.ts +2 -2
  56. package/dist/types/utils/index.d.ts +4 -1
  57. package/dist/types/utils/scroll-gutter.d.ts +3 -0
  58. package/dist/types/whitespace/index.d.ts +1 -0
  59. package/dist/types-ts4.5/types/annotation/index.d.ts +2 -2
  60. package/dist/types-ts4.5/utils/annotation/index.d.ts +2 -2
  61. package/dist/types-ts4.5/utils/index.d.ts +4 -1
  62. package/dist/types-ts4.5/utils/scroll-gutter.d.ts +3 -0
  63. package/dist/types-ts4.5/whitespace/index.d.ts +1 -0
  64. package/package.json +3 -8
  65. package/whitespace/package.json +15 -0
  66. /package/dist/cjs/{utils → whitespace}/whitespace.js +0 -0
  67. /package/dist/es2019/{utils → whitespace}/whitespace.js +0 -0
  68. /package/dist/esm/{utils → whitespace}/whitespace.js +0 -0
  69. /package/dist/types/{utils → whitespace}/whitespace.d.ts +0 -0
  70. /package/dist/types-ts4.5/{utils → whitespace}/whitespace.d.ts +0 -0
package/CHANGELOG.md CHANGED
@@ -1,5 +1,28 @@
1
1
  # @atlaskit/editor-common
2
2
 
3
+ ## 84.3.1
4
+
5
+ ### Patch Changes
6
+
7
+ - [#118071](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/118071)
8
+ [`8001b542d9e11`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/8001b542d9e11) -
9
+ [ED-24018] removes the feature flag
10
+ 'platform.editor.a11y-focus-order-for-element-browser-categories_ztiw1'
11
+
12
+ ## 84.3.0
13
+
14
+ ### Minor Changes
15
+
16
+ - [#117973](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/117973)
17
+ [`6e37bac62083f`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/6e37bac62083f) -
18
+ moved one const, added new entry point for other and deprecated
19
+
20
+ ### Patch Changes
21
+
22
+ - [#113218](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/113218)
23
+ [`d1b428ec29d68`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/d1b428ec29d68) -
24
+ [ED-23765] migrate inline node commenting feature flags to statsig feature gate
25
+
3
26
  ## 84.2.0
4
27
 
5
28
  ### Minor Changes
@@ -47,6 +47,9 @@
47
47
  {
48
48
  "path": "../../custom-steps/afm-jira/tsconfig.json"
49
49
  },
50
+ {
51
+ "path": "../../../design-system/dropdown-menu/afm-jira/tsconfig.json"
52
+ },
50
53
  {
51
54
  "path": "../../editor-json-transformer/afm-jira/tsconfig.json"
52
55
  },
@@ -8,13 +8,11 @@ Object.defineProperty(exports, "__esModule", {
8
8
  exports.default = void 0;
9
9
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
10
10
  var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
11
- var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));
12
11
  var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
13
12
  var _react = _interopRequireWildcard(require("react"));
14
13
  var _react2 = require("@emotion/react");
15
14
  var _analyticsNext = require("@atlaskit/analytics-next");
16
15
  var _customThemeButton = _interopRequireDefault(require("@atlaskit/button/custom-theme-button"));
17
- var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
18
16
  var _colors = require("@atlaskit/theme/colors");
19
17
  var _analytics = require("../../analytics");
20
18
  var _constants = require("../constants");
@@ -32,20 +30,14 @@ function CategoryList(_ref) {
32
30
  var _ref$categories = _ref.categories,
33
31
  categories = _ref$categories === void 0 ? [] : _ref$categories,
34
32
  props = (0, _objectWithoutProperties2.default)(_ref, _excluded);
35
- var _React$useState = _react.default.useState(null),
36
- _React$useState2 = (0, _slicedToArray2.default)(_React$useState, 2),
37
- focusedCategoryIndexState = _React$useState2[0],
38
- setFocusedCategoryIndexState = _React$useState2[1];
39
- var focusedCategoryIndexProp = props.focusedCategoryIndex,
40
- setFocusedCategoryIndexProp = props.setFocusedCategoryIndex,
33
+ var focusedCategoryIndex = props.focusedCategoryIndex,
34
+ setFocusedCategoryIndex = props.setFocusedCategoryIndex,
41
35
  onSelectCategory = props.onSelectCategory;
42
- var focusedCategoryIndex = (0, _platformFeatureFlags.getBooleanFF)('platform.editor.a11y-focus-order-for-element-browser-categories_ztiw1') ? focusedCategoryIndexProp : focusedCategoryIndexState;
43
- var setFocusedCategoryIndex = (0, _platformFeatureFlags.getBooleanFF)('platform.editor.a11y-focus-order-for-element-browser-categories_ztiw1') ? setFocusedCategoryIndexProp : setFocusedCategoryIndexState;
44
36
  return (0, _react2.jsx)(_react.Fragment, null, categories.map(function (category, index) {
45
37
  var categoriesLength = categories === null || categories === void 0 ? void 0 : categories.length;
46
38
  var selectNextCategory;
47
39
  var selectPreviousCategory;
48
- if ((0, _platformFeatureFlags.getBooleanFF)('platform.editor.a11y-focus-order-for-element-browser-categories_ztiw1') && categoriesLength > 1) {
40
+ if (categoriesLength > 1) {
49
41
  selectNextCategory = function selectNextCategory() {
50
42
  if (index !== categoriesLength - 1) {
51
43
  setFocusedCategoryIndex(index + 1);
@@ -93,9 +85,6 @@ function CategoryListItem(_ref2) {
93
85
  selectNextCategory = _ref2.selectNextCategory;
94
86
  var ref = (0, _useFocus.default)(focus);
95
87
  var onClick = (0, _react.useCallback)(function () {
96
- if (!(0, _platformFeatureFlags.getBooleanFF)('platform.editor.a11y-focus-order-for-element-browser-categories_ztiw1')) {
97
- onSelectCategory(category);
98
- }
99
88
  /**
100
89
  * When user double clicks on same category, focus on first item.
101
90
  */
@@ -104,9 +93,7 @@ function CategoryListItem(_ref2) {
104
93
  } else {
105
94
  setFocusedCategoryIndex(index);
106
95
  }
107
- if ((0, _platformFeatureFlags.getBooleanFF)('platform.editor.a11y-focus-order-for-element-browser-categories_ztiw1')) {
108
- onSelectCategory(category);
109
- }
96
+ onSelectCategory(category);
110
97
  (0, _analytics.fireAnalyticsEvent)(createAnalyticsEvent)({
111
98
  payload: {
112
99
  action: _analytics.ACTION.CLICKED,
@@ -180,7 +167,7 @@ function CategoryListItem(_ref2) {
180
167
  isSelected: selectedCategory === category.name,
181
168
  onClick: onClick,
182
169
  onFocus: onFocus,
183
- onKeyDown: (0, _platformFeatureFlags.getBooleanFF)('platform.editor.a11y-focus-order-for-element-browser-categories_ztiw1') ? onKeyDown : undefined,
170
+ onKeyDown: onKeyDown,
184
171
  theme: getTheme,
185
172
  role: "tab",
186
173
  "aria-selected": selectedCategory === category.name ? 'true' : 'false',
@@ -137,7 +137,7 @@ function ElementList(_ref) {
137
137
  ,
138
138
  className: "element-item-wrapper",
139
139
  css: elementItemWrapper,
140
- onKeyDown: (0, _platformFeatureFlags.getBooleanFF)('platform.editor.a11y-focus-order-for-element-browser-categories_ztiw1') ? function (e) {
140
+ onKeyDown: function onKeyDown(e) {
141
141
  if (e.key === 'Tab') {
142
142
  if (e.shiftKey && index === 0) {
143
143
  if (setFocusedCategoryIndex) {
@@ -157,7 +157,7 @@ function ElementList(_ref) {
157
157
  setFocusedItemIndex(items.length - 1);
158
158
  }
159
159
  }
160
- } : undefined
160
+ }
161
161
  }, (0, _react2.jsx)(MemoizedElementItem, (0, _extends2.default)({
162
162
  inlineMode: !fullMode,
163
163
  index: index,
@@ -193,7 +193,7 @@ function ElementList(_ref) {
193
193
  ,
194
194
  className: "element-item-wrapper",
195
195
  css: elementItemWrapper,
196
- onKeyDown: (0, _platformFeatureFlags.getBooleanFF)('platform.editor.a11y-focus-order-for-element-browser-categories_ztiw1') ? function (e) {
196
+ onKeyDown: function onKeyDown(e) {
197
197
  if (e.key === 'Tab') {
198
198
  if (e.shiftKey && index === 0) {
199
199
  if (setFocusedCategoryIndex) {
@@ -213,7 +213,7 @@ function ElementList(_ref) {
213
213
  setFocusedItemIndex(items.length - 1);
214
214
  }
215
215
  }
216
- } : undefined
216
+ }
217
217
  }, (0, _react2.jsx)(MemoizedElementItem, (0, _extends2.default)({
218
218
  inlineMode: !fullMode,
219
219
  index: index,
@@ -243,7 +243,7 @@ function ElementList(_ref) {
243
243
  disableWidth: true
244
244
  }, function (_ref5) {
245
245
  var height = _ref5.height;
246
- return (0, _platformFeatureFlags.getBooleanFF)('platform.editor.a11y-element-browser') ? (0, _react2.jsx)(_reactVirtualized.Grid, (0, _extends2.default)({
246
+ return (0, _platformFeatureFlags.fg)('platform.editor.a11y-element-browser') ? (0, _react2.jsx)(_reactVirtualized.Grid, (0, _extends2.default)({
247
247
  cellRenderer: gridCellRenderer,
248
248
  height: height,
249
249
  width: containerWidth - _constants2.ELEMENT_LIST_PADDING * 2 // containerWidth - padding on Left/Right (for focus outline)
@@ -12,7 +12,6 @@ var _react = _interopRequireWildcard(require("react"));
12
12
  var _react2 = require("@emotion/react");
13
13
  var _reactIntlNext = require("react-intl-next");
14
14
  var _analyticsNext = require("@atlaskit/analytics-next");
15
- var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
16
15
  var _analytics = require("../../analytics");
17
16
  var _constants = require("../constants");
18
17
  var _useContainerWidth2 = _interopRequireDefault(require("../hooks/use-container-width"));
@@ -119,6 +118,7 @@ var categoryListWrapper = (0, _react2.css)(mobileCategoryListWrapper, {
119
118
  flexDirection: 'column'
120
119
  });
121
120
  function StatelessElementBrowser(props) {
121
+ var _props$categories;
122
122
  var items = props.items,
123
123
  onSelectItem = props.onSelectItem,
124
124
  onInsertItem = props.onInsertItem,
@@ -137,21 +137,18 @@ function StatelessElementBrowser(props) {
137
137
  setColumnCount = _useState2[1];
138
138
  var selectedCategoryIndex;
139
139
  var isFocusSearch;
140
- if ((0, _platformFeatureFlags.getBooleanFF)('platform.editor.a11y-focus-order-for-element-browser-categories_ztiw1')) {
141
- var _props$categories;
142
- selectedCategoryIndex = (_props$categories = props.categories) === null || _props$categories === void 0 ? void 0 : _props$categories.findIndex(function (category) {
143
- return category.name === selectedCategory;
144
- });
145
- if (showCategories) {
146
- var isEmptySearchTerm = !searchTerm || (searchTerm === null || searchTerm === void 0 ? void 0 : searchTerm.length) === 0;
147
- if (!isEmptySearchTerm) {
148
- // clear the flag if the search happens after a user has chosen the category
149
- categoryBeenChosen.current = false;
150
- }
151
- // A11Y: if categories exists, on the initial render search element should receive focus.
152
- // After user pick some category the category should stay focused.
153
- isFocusSearch = !categoryBeenChosen.current || !isEmptySearchTerm;
140
+ selectedCategoryIndex = (_props$categories = props.categories) === null || _props$categories === void 0 ? void 0 : _props$categories.findIndex(function (category) {
141
+ return category.name === selectedCategory;
142
+ });
143
+ if (showCategories) {
144
+ var isEmptySearchTerm = !searchTerm || (searchTerm === null || searchTerm === void 0 ? void 0 : searchTerm.length) === 0;
145
+ if (!isEmptySearchTerm) {
146
+ // clear the flag if the search happens after a user has chosen the category
147
+ categoryBeenChosen.current = false;
154
148
  }
149
+ // A11Y: if categories exists, on the initial render search element should receive focus.
150
+ // After user pick some category the category should stay focused.
151
+ isFocusSearch = !categoryBeenChosen.current || !isEmptySearchTerm;
155
152
  }
156
153
  var _useSelectAndFocusOnA = (0, _useSelectAndFocusOnArrowNavigation.default)(items.length - 1, columnCount, !!viewMoreItem, isFocusSearch),
157
154
  selectedItemIndex = _useSelectAndFocusOnA.selectedItemIndex,
@@ -193,22 +190,14 @@ function StatelessElementBrowser(props) {
193
190
  */
194
191
  var selectedItem = selectedItemIndex !== undefined ? items[selectedItemIndex] : null;
195
192
  var onItemsEnterTabKeyPress = (0, _react.useCallback)(function (e) {
196
- if ((0, _platformFeatureFlags.getBooleanFF)('platform.editor.a11y-focus-order-for-element-browser-categories_ztiw1')) {
197
- if (e.key !== 'Enter' && (e.key !== 'Tab' || !showCategories)) {
198
- return;
199
- }
200
- } else {
201
- if (e.key !== 'Enter') {
202
- return;
203
- }
193
+ if (e.key !== 'Enter' && (e.key !== 'Tab' || !showCategories)) {
194
+ return;
204
195
  }
205
- if ((0, _platformFeatureFlags.getBooleanFF)('platform.editor.a11y-focus-order-for-element-browser-categories_ztiw1')) {
206
- if (showCategories && e.key === 'Tab' && selectedCategoryIndex !== undefined) {
207
- // A11Y: Set focus on first category if tab pressed on search
208
- setFocusedCategoryIndex(selectedCategoryIndex);
209
- e.preventDefault();
210
- return;
211
- }
196
+ if (showCategories && e.key === 'Tab' && selectedCategoryIndex !== undefined) {
197
+ // A11Y: Set focus on first category if tab pressed on search
198
+ setFocusedCategoryIndex(selectedCategoryIndex);
199
+ e.preventDefault();
200
+ return;
212
201
  }
213
202
  if (onInsertItem && selectedItem != null) {
214
203
  onInsertItem(selectedItem);
@@ -259,7 +248,7 @@ function StatelessElementBrowser(props) {
259
248
  focusedCategoryIndex: focusedCategoryIndex,
260
249
  setFocusedCategoryIndex: setFocusedCategoryIndex,
261
250
  selectedCategoryIndex: selectedCategoryIndex,
262
- onSelectCategory: (0, _platformFeatureFlags.getBooleanFF)('platform.editor.a11y-focus-order-for-element-browser-categories_ztiw1') ? onSelectCategoryCB : onSelectCategory
251
+ onSelectCategory: onSelectCategoryCB
263
252
  })));
264
253
  }
265
254
  function MobileBrowser(_ref) {
@@ -8,7 +8,6 @@ exports.ensureSafeIndex = exports.default = exports.ACTIONS = void 0;
8
8
  var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));
9
9
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
10
10
  var _react = require("react");
11
- var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
12
11
  function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
13
12
  function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
14
13
  /**
@@ -70,7 +69,6 @@ var reducer = function reducer(state, action) {
70
69
  case ACTIONS.MOVE:
71
70
  return moveReducer(state, action);
72
71
  }
73
- return state;
74
72
  };
75
73
  var moveReducer = function moveReducer(state, action) {
76
74
  var listSize = state.listSize,
@@ -197,13 +195,11 @@ function useSelectAndFocusOnArrowNavigation(listSize, step, canFocusViewMore, is
197
195
  var payload = _objectSpread(_objectSpread({}, initialState), {}, {
198
196
  listSize: listSize
199
197
  });
200
- if ((0, _platformFeatureFlags.getBooleanFF)('platform.editor.a11y-focus-order-for-element-browser-categories_ztiw1')) {
201
- // A11Y: if categories exist ,on the initial render search element should receive focus.
202
- // After user pick some category the category should stay focused.
203
- payload = Object.assign(payload, {
204
- focusOnSearch: isFocusSearch !== null && isFocusSearch !== void 0 ? isFocusSearch : initialState.focusOnSearch
205
- });
206
- }
198
+ // A11Y: if categories exist ,on the initial render search element should receive focus.
199
+ // After user pick some category the category should stay focused.
200
+ payload = Object.assign(payload, {
201
+ focusOnSearch: isFocusSearch !== null && isFocusSearch !== void 0 ? isFocusSearch : initialState.focusOnSearch
202
+ });
207
203
  dispatch({
208
204
  type: ACTIONS.UPDATE_STATE,
209
205
  payload: payload
@@ -216,20 +212,15 @@ function useSelectAndFocusOnArrowNavigation(listSize, step, canFocusViewMore, is
216
212
  focusOnSearch: false,
217
213
  focusOnViewMore: false
218
214
  };
219
- if ((0, _platformFeatureFlags.getBooleanFF)('platform.editor.a11y-focus-order-for-element-browser-categories_ztiw1')) {
220
- payload = Object.assign(payload, {
221
- focusedCategoryIndex: undefined
222
- });
223
- }
215
+ payload = Object.assign(payload, {
216
+ focusedCategoryIndex: undefined
217
+ });
224
218
  dispatch({
225
219
  type: ACTIONS.UPDATE_STATE,
226
220
  payload: payload
227
221
  });
228
222
  }, [dispatch]);
229
223
  var setFocusedCategoryIndex = (0, _react.useCallback)(function (index) {
230
- if (!(0, _platformFeatureFlags.getBooleanFF)('platform.editor.a11y-focus-order-for-element-browser-categories_ztiw1')) {
231
- return;
232
- }
233
224
  var payload = {
234
225
  focusOnSearch: false,
235
226
  focusOnViewMore: false,
@@ -8,7 +8,7 @@ exports.ExtensionNodeWrapper = void 0;
8
8
  var _react = _interopRequireDefault(require("react"));
9
9
  var _react2 = require("@emotion/react");
10
10
  var _classnames = _interopRequireDefault(require("classnames"));
11
- var _utils = require("../utils");
11
+ var _whitespace = require("../whitespace");
12
12
  /** @jsx jsx */
13
13
 
14
14
  // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
@@ -46,6 +46,6 @@ var ExtensionNodeWrapper = exports.ExtensionNodeWrapper = function ExtensionNode
46
46
  (0, _react2.jsx)("span", {
47
47
  className: wrapperClassNames,
48
48
  css: styles
49
- }, children, nodeType === 'inlineExtension' && _utils.ZERO_WIDTH_SPACE)
49
+ }, children, nodeType === 'inlineExtension' && _whitespace.ZERO_WIDTH_SPACE)
50
50
  );
51
51
  };
@@ -140,22 +140,17 @@ var transformSmartCharsMentionsAndEmojis = exports.transformSmartCharsMentionsAn
140
140
  var applyMarkOnRange = exports.applyMarkOnRange = function applyMarkOnRange(from, to, removeMark, mark, tr) {
141
141
  var schema = tr.doc.type.schema;
142
142
  var code = schema.marks.code;
143
- var inlineCard = schema.nodes.inlineCard;
144
143
  if (mark.type === code) {
145
- (0, _platformFeatureFlags.getBooleanFF)('platform.editor.simplify-inline-cards-in-code-blocks_jw6t1') ? transformNonTextNodesToText(from, to, tr) : transformSmartCharsMentionsAndEmojis(from, to, tr);
144
+ (0, _platformFeatureFlags.fg)('platform.editor.simplify-inline-cards-in-code-blocks_jw6t1') ? transformNonTextNodesToText(from, to, tr) : transformSmartCharsMentionsAndEmojis(from, to, tr);
146
145
  }
147
146
  tr.doc.nodesBetween(tr.mapping.map(from), tr.mapping.map(to), function (node, pos) {
148
- if ((0, _platformFeatureFlags.getBooleanFF)('platform.editor.allow-inline-comments-for-inline-nodes-round-2_ctuxz')) {
147
+ if ((0, _platformFeatureFlags.fg)('editor_inline_comments_on_inline_nodes')) {
149
148
  if (!node.isText) {
150
149
  var isAllowedInlineNode = ['emoji', 'status', 'date', 'mention', 'inlineCard'].includes(node.type.name);
151
150
  if (!isAllowedInlineNode) {
152
151
  return true;
153
152
  }
154
153
  }
155
- } else if ((0, _platformFeatureFlags.getBooleanFF)('platform.editor.allow-inline-comments-for-inline-nodes')) {
156
- if (!node.isText && node.type !== inlineCard) {
157
- return true;
158
- }
159
154
  } else {
160
155
  if (!node.isText) {
161
156
  return true;
@@ -11,7 +11,7 @@ var annotationMessages = exports.annotationMessages = (0, _reactIntlNext.defineM
11
11
  defaultMessage: 'Comment',
12
12
  description: 'Create/add an inline comment based on the users selection'
13
13
  },
14
- // TODO: Remove this message when the platform.editor.allow-inline-comments-for-inline-nodes-round-2_ctuxz FF is removed
14
+ // TODO: Remove this message when the editor_inline_comments_on_inline_nodes FF is removed
15
15
  createCommentInvalid: {
16
16
  id: 'fabric.editor.createCommentInvalid',
17
17
  defaultMessage: 'You can only comment on text and headings',
@@ -17,7 +17,7 @@ function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return
17
17
  function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
18
18
  var SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
19
19
  var packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
20
- var packageVersion = "84.2.0";
20
+ var packageVersion = "84.3.1";
21
21
  var sanitiseSentryEvents = function sanitiseSentryEvents(data, _hint) {
22
22
  // Remove URL as it has UGC
23
23
  // TODO: Sanitise the URL instead of just removing it
@@ -13,6 +13,7 @@ var _react2 = require("@emotion/react");
13
13
  var _analytics = require("../analytics");
14
14
  var _ErrorBoundary = require("../ui/ErrorBoundary");
15
15
  var _utils = require("../utils");
16
+ var _whitespace = require("../whitespace");
16
17
  var _generateUniqueNodeKey = require("./generateUniqueNodeKey");
17
18
  function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
18
19
  function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; } /** @jsx jsx */ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
@@ -178,7 +179,7 @@ function getPortalChildren(_ref2) {
178
179
  className: "zeroWidthSpaceContainer"
179
180
  }, (0, _react2.jsx)("span", {
180
181
  className: "".concat(inlineNodeViewClassname, "AddZeroWidthSpace")
181
- }), _utils.ZERO_WIDTH_SPACE), (0, _react2.jsx)(Component, (0, _extends2.default)({
182
+ }), _whitespace.ZERO_WIDTH_SPACE), (0, _react2.jsx)(Component, (0, _extends2.default)({
182
183
  view: nodeViewParams.view
183
184
  // TODO: ED-13910 - Remove the boolean to fix the prosemirror view type
184
185
  ,
@@ -191,7 +192,7 @@ function getPortalChildren(_ref2) {
191
192
  contentEditable: "false"
192
193
  }, (0, _react2.jsx)("span", {
193
194
  className: "".concat(inlineNodeViewClassname, "AddZeroWidthSpace")
194
- }), _utils.ZERO_WIDTH_SPACE) :
195
+ }), _whitespace.ZERO_WIDTH_SPACE) :
195
196
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
196
197
  (0, _react2.jsx)("span", {
197
198
  className: "".concat(inlineNodeViewClassname, "AddZeroWidthSpace")
@@ -25,7 +25,7 @@ var BlockAnnotationSharedClassNames = exports.BlockAnnotationSharedClassNames =
25
25
  var Yellow100 = 'rgb(255, 247, 214)';
26
26
  var Y200a = 'rgba(255, 196, 0, 0.82)';
27
27
  var AnnotationSharedCSSByState = exports.AnnotationSharedCSSByState = function AnnotationSharedCSSByState() {
28
- if ((0, _platformFeatureFlags.getBooleanFF)('platform.editor.allow-inline-comments-for-inline-nodes-round-2_ctuxz')) {
28
+ if ((0, _platformFeatureFlags.fg)('editor_inline_comments_on_inline_nodes')) {
29
29
  // NOTE: These styles are shared between renderer and editor. Sometimes they
30
30
  // need different selectors and other times they apply the same attributes
31
31
  // in a different way. For example in renderer the focus styles are an
@@ -55,38 +55,6 @@ var AnnotationSharedCSSByState = exports.AnnotationSharedCSSByState = function A
55
55
  borderBottomColor: "var(--ds-border-accent-yellow, ".concat(Y200a, ")")
56
56
  })
57
57
  };
58
- } else if ((0, _platformFeatureFlags.getBooleanFF)('platform.editor.allow-inline-comments-for-inline-nodes')) {
59
- return {
60
- focus: (0, _react.css)({
61
- background: "var(--ds-background-accent-yellow-subtler, ".concat(_colors.Y75, ")"),
62
- borderBottom: "2px solid ".concat("var(--ds-border-accent-yellow, ".concat(_colors.Y300, ")")),
63
- boxShadow: "var(--ds-shadow-overlay, ".concat("1px 2px 3px ".concat(_colors.N60A, ", -1px 2px 3px ").concat(_colors.N60A), ")"),
64
- cursor: 'pointer',
65
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors -- Ignored via go/DSP-18766
66
- '&:has(.card)': {
67
- fontSize: '1.5rem',
68
- lineHeight: '1.2rem',
69
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
70
- '& > *': {
71
- fontSize: '16px'
72
- }
73
- }
74
- }),
75
- blur: (0, _react.css)({
76
- background: "var(--ds-background-accent-yellow-subtlest, ".concat(Yellow100, ")"),
77
- borderBottom: "2px solid ".concat("var(--ds-border-accent-yellow, ".concat(Y200a, ")")),
78
- cursor: 'pointer',
79
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors -- Ignored via go/DSP-18766
80
- '&:has(.card)': {
81
- fontSize: '1.5rem',
82
- lineHeight: '1.2rem',
83
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
84
- '& > *': {
85
- fontSize: '16px'
86
- }
87
- }
88
- })
89
- };
90
58
  } else {
91
59
  return {
92
60
  focus: (0, _react.css)({
@@ -107,7 +75,7 @@ var AnnotationSharedCSSByState = exports.AnnotationSharedCSSByState = function A
107
75
  }
108
76
  };
109
77
  var annotationSharedStyles = exports.annotationSharedStyles = function annotationSharedStyles() {
110
- return (0, _platformFeatureFlags.getBooleanFF)('platform.editor.allow-inline-comments-for-inline-nodes-round-2_ctuxz') ? // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression -- `AnnotationSharedCSSByState()` is not safe in object syntax
78
+ return (0, _platformFeatureFlags.fg)('editor_inline_comments_on_inline_nodes') ? // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression -- `AnnotationSharedCSSByState()` is not safe in object syntax
111
79
  (0, _react.css)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n\t\t\t\t.ProseMirror {\n\t\t\t\t\t.", ",\n\t\t\t\t\t\t.", ",\n\t\t\t\t\t\t.", " {\n\t\t\t\t\t\t", ";\n\t\t\t\t\t}\n\n\t\t\t\t\t.", " {\n\t\t\t\t\t\t", ";\n\t\t\t\t\t}\n\n\t\t\t\t\t.", " {\n\t\t\t\t\t\t", ";\n\t\t\t\t\t\tcursor: initial;\n\t\t\t\t\t}\n\n\t\t\t\t\t.", " {\n\t\t\t\t\t\t", ";\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t"])), AnnotationSharedClassNames.blur, AnnotationSharedClassNames.focus, AnnotationSharedClassNames.draft, AnnotationSharedCSSByState().common, AnnotationSharedClassNames.focus, AnnotationSharedCSSByState().focus, AnnotationSharedClassNames.draft, AnnotationSharedCSSByState().focus, AnnotationSharedClassNames.blur, AnnotationSharedCSSByState().blur) : // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression -- `AnnotationSharedCSSByState()` is not safe in object syntax
112
80
  (0, _react.css)(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2.default)(["\n\t\t\t\t.ProseMirror {\n\t\t\t\t\t.", " {\n\t\t\t\t\t\t", ";\n\t\t\t\t\t}\n\n\t\t\t\t\t.", " {\n\t\t\t\t\t\t", ";\n\t\t\t\t\t\tcursor: initial;\n\t\t\t\t\t}\n\n\t\t\t\t\t.", " {\n\t\t\t\t\t\t", ";\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t"])), AnnotationSharedClassNames.focus, AnnotationSharedCSSByState().focus, AnnotationSharedClassNames.draft, AnnotationSharedCSSByState().focus, AnnotationSharedClassNames.blur, AnnotationSharedCSSByState().blur);
113
81
  };
@@ -16,4 +16,4 @@ var DATASOURCE_INNER_CONTAINER_CLASSNAME = exports.DATASOURCE_INNER_CONTAINER_CL
16
16
  var FLOATING_TOOLBAR_LINKPICKER_CLASSNAME = exports.FLOATING_TOOLBAR_LINKPICKER_CLASSNAME = 'card-floating-toolbar--link-picker';
17
17
 
18
18
  // eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression, @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
19
- var smartCardStyles = exports.smartCardStyles = (0, _react.css)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n\t.", " {\n\t\tmax-width: calc(100% - 20px);\n\t\tvertical-align: top;\n\t\tword-break: break-all;\n\t\t", "\n\t\t.card {\n\t\t\tpadding-left: ", ";\n\t\t\tpadding-right: ", ";\n\t\t\tpadding-top: 0.5em;\n\t\t\tpadding-bottom: 0.5em;\n\t\t\tmargin-bottom: -0.5em;\n\n\t\t\t.", " > a:focus {\n\t\t\t\t", "\n\t\t\t}\n\t\t}\n\n\t\t&.", " .", " > a {\n\t\t\t", "\n\t\t}\n\t\t.", " > a {\n\t\t\t/* EDM-1717: box-shadow Safari fix start */\n\t\t\tz-index: 1;\n\t\t\tposition: relative;\n\t\t\t/* EDM-1717: box-shadow Safari fix end */\n\t\t}\n\n\t\t&.danger {\n\t\t\t.", " > a {\n\t\t\t\tbox-shadow: 0 0 0 1px ", ";\n\t\t\t\t/* EDM-1717: box-shadow Safari fix start */\n\t\t\t\tz-index: 2;\n\t\t\t\t/* EDM-1717: box-shadow Safari fix end */\n\t\t\t}\n\t\t}\n\t}\n\n\t.", " {\n\t\t.", " > div {\n\t\t\tcursor: pointer;\n\t\t}\n\n\t\t&.", " .", " > div {\n\t\t\t", "\n\t\t\tborder-radius: ", ";\n\t\t}\n\n\t\t&.danger {\n\t\t\t.", " > div {\n\t\t\t\tbox-shadow: 0 0 0 1px ", " !important;\n\t\t\t}\n\t\t}\n\t}\n\n\t.", ".", " {\n\t\tmax-width: 100%;\n\t\tdisplay: flex;\n\t\tjustify-content: center;\n\n\t\t.", " {\n\t\t\tcursor: pointer;\n\t\t\tbackground-color: ", ";\n\t\t\tborder-radius: ", ";\n\t\t\tborder: 1px solid ", ";\n\t\t}\n\n\t\t&.", " {\n\t\t\t.", " {\n\t\t\t\t", "\n\t\t\t}\n\t\t}\n\n\t\t&.danger {\n\t\t\t.", " {\n\t\t\t\tbox-shadow: 0 0 0 1px ", ";\n\t\t\t}\n\t\t}\n\t}\n\n\t.", " {\n\t\t.", " > div {\n\t\t\tcursor: pointer;\n\t\t\t&::after {\n\t\t\t\ttransition: box-shadow 0s;\n\t\t\t}\n\t\t}\n\n\t\t&.", " .", " > div::after {\n\t\t\t", "\n\t\t}\n\n\t\t&.danger {\n\t\t\t.media-card-frame::after {\n\t\t\t\tbox-shadow: 0 0 0 1px ", " !important;\n\t\t\t\tbackground: ", " !important;\n\t\t\t}\n\t\t\t.richMedia-resize-handle-right::after,\n\t\t\t.richMedia-resize-handle-left::after {\n\t\t\t\tbackground: ", ";\n\t\t\t}\n\t\t}\n\t}\n\n\t.", " {\n\t\tpadding: 0;\n\t}\n"])), _smartCard.SmartCardSharedCssClassName.INLINE_CARD_CONTAINER, (0, _platformFeatureFlags.getBooleanFF)('platform.editor.allow-inline-comments-for-inline-nodes') ? ".card-with-comment {\n background: ".concat("var(--ds-background-accent-yellow-subtler, ".concat(_colors.Y75, ")"), ";\n border-bottom: 2px solid ", "var(--ds-border-accent-yellow, ".concat(_colors.Y300, ")"), ";\n box-shadow: ", "var(--ds-shadow-overlay, ".concat("1px 2px 3px ".concat(_colors.N60A, ", -1px 2px 3px ").concat(_colors.N60A), ")"), ";\n }") : '', "var(--ds-space-025, 2px)", "var(--ds-space-025, 2px)", _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, (0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow]), _editorSharedStyles.akEditorSelectedNodeClassName, _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, (0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow]), _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, "var(--ds-border-danger, ".concat(_editorSharedStyles.akEditorDeleteBorder, ")"), _smartCard.SmartCardSharedCssClassName.BLOCK_CARD_CONTAINER, _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, _editorSharedStyles.akEditorSelectedNodeClassName, _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, (0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow]), "var(--ds-border-radius-200, 8px)", _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, "var(--ds-border-danger, ".concat(_editorSharedStyles.akEditorDeleteBorder, ")"), _smartCard.SmartCardSharedCssClassName.DATASOURCE_CONTAINER, _smartCard.SmartCardSharedCssClassName.BLOCK_CARD_CONTAINER, DATASOURCE_INNER_CONTAINER_CLASSNAME, "var(--ds-background-neutral-subtle, ".concat(_colors.N0, ")"), "var(--ds-border-radius-200, 8px)", "var(--ds-border, ".concat(_colors.N40, ")"), _editorSharedStyles.akEditorSelectedNodeClassName, DATASOURCE_INNER_CONTAINER_CLASSNAME, (0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow]), DATASOURCE_INNER_CONTAINER_CLASSNAME, "var(--ds-border-danger, ".concat(_editorSharedStyles.akEditorDeleteBorder, ")"), _smartCard.SmartCardSharedCssClassName.EMBED_CARD_CONTAINER, _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, _editorSharedStyles.akEditorSelectedNodeClassName, _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, (0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow]), "var(--ds-border-danger, ".concat(_editorSharedStyles.akEditorDeleteBorder, ")"), "var(--ds-background-danger, ".concat(_editorSharedStyles.akEditorDeleteBackground, ")"), "var(--ds-border-danger, ".concat(_editorSharedStyles.akEditorDeleteBorder, ")"), FLOATING_TOOLBAR_LINKPICKER_CLASSNAME);
19
+ var smartCardStyles = exports.smartCardStyles = (0, _react.css)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n\t.", " {\n\t\tmax-width: calc(100% - 20px);\n\t\tvertical-align: top;\n\t\tword-break: break-all;\n\t\t", "\n\t\t.card {\n\t\t\tpadding-left: ", ";\n\t\t\tpadding-right: ", ";\n\t\t\tpadding-top: 0.5em;\n\t\t\tpadding-bottom: 0.5em;\n\t\t\tmargin-bottom: -0.5em;\n\n\t\t\t.", " > a:focus {\n\t\t\t\t", "\n\t\t\t}\n\t\t}\n\n\t\t&.", " .", " > a {\n\t\t\t", "\n\t\t}\n\t\t.", " > a {\n\t\t\t/* EDM-1717: box-shadow Safari fix start */\n\t\t\tz-index: 1;\n\t\t\tposition: relative;\n\t\t\t/* EDM-1717: box-shadow Safari fix end */\n\t\t}\n\n\t\t&.danger {\n\t\t\t.", " > a {\n\t\t\t\tbox-shadow: 0 0 0 1px ", ";\n\t\t\t\t/* EDM-1717: box-shadow Safari fix start */\n\t\t\t\tz-index: 2;\n\t\t\t\t/* EDM-1717: box-shadow Safari fix end */\n\t\t\t}\n\t\t}\n\t}\n\n\t.", " {\n\t\t.", " > div {\n\t\t\tcursor: pointer;\n\t\t}\n\n\t\t&.", " .", " > div {\n\t\t\t", "\n\t\t\tborder-radius: ", ";\n\t\t}\n\n\t\t&.danger {\n\t\t\t.", " > div {\n\t\t\t\tbox-shadow: 0 0 0 1px ", " !important;\n\t\t\t}\n\t\t}\n\t}\n\n\t.", ".", " {\n\t\tmax-width: 100%;\n\t\tdisplay: flex;\n\t\tjustify-content: center;\n\n\t\t.", " {\n\t\t\tcursor: pointer;\n\t\t\tbackground-color: ", ";\n\t\t\tborder-radius: ", ";\n\t\t\tborder: 1px solid ", ";\n\t\t}\n\n\t\t&.", " {\n\t\t\t.", " {\n\t\t\t\t", "\n\t\t\t}\n\t\t}\n\n\t\t&.danger {\n\t\t\t.", " {\n\t\t\t\tbox-shadow: 0 0 0 1px ", ";\n\t\t\t}\n\t\t}\n\t}\n\n\t.", " {\n\t\t.", " > div {\n\t\t\tcursor: pointer;\n\t\t\t&::after {\n\t\t\t\ttransition: box-shadow 0s;\n\t\t\t}\n\t\t}\n\n\t\t&.", " .", " > div::after {\n\t\t\t", "\n\t\t}\n\n\t\t&.danger {\n\t\t\t.media-card-frame::after {\n\t\t\t\tbox-shadow: 0 0 0 1px ", " !important;\n\t\t\t\tbackground: ", " !important;\n\t\t\t}\n\t\t\t.richMedia-resize-handle-right::after,\n\t\t\t.richMedia-resize-handle-left::after {\n\t\t\t\tbackground: ", ";\n\t\t\t}\n\t\t}\n\t}\n\n\t.", " {\n\t\tpadding: 0;\n\t}\n"])), _smartCard.SmartCardSharedCssClassName.INLINE_CARD_CONTAINER, (0, _platformFeatureFlags.fg)('editor_inline_comments_on_inline_nodes') ? ".card-with-comment {\n background: ".concat("var(--ds-background-accent-yellow-subtler, ".concat(_colors.Y75, ")"), ";\n border-bottom: 2px solid ", "var(--ds-border-accent-yellow, ".concat(_colors.Y300, ")"), ";\n box-shadow: ", "var(--ds-shadow-overlay, ".concat("1px 2px 3px ".concat(_colors.N60A, ", -1px 2px 3px ").concat(_colors.N60A), ")"), ";\n }") : '', "var(--ds-space-025, 2px)", "var(--ds-space-025, 2px)", _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, (0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow]), _editorSharedStyles.akEditorSelectedNodeClassName, _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, (0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow]), _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, "var(--ds-border-danger, ".concat(_editorSharedStyles.akEditorDeleteBorder, ")"), _smartCard.SmartCardSharedCssClassName.BLOCK_CARD_CONTAINER, _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, _editorSharedStyles.akEditorSelectedNodeClassName, _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, (0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow]), "var(--ds-border-radius-200, 8px)", _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, "var(--ds-border-danger, ".concat(_editorSharedStyles.akEditorDeleteBorder, ")"), _smartCard.SmartCardSharedCssClassName.DATASOURCE_CONTAINER, _smartCard.SmartCardSharedCssClassName.BLOCK_CARD_CONTAINER, DATASOURCE_INNER_CONTAINER_CLASSNAME, "var(--ds-background-neutral-subtle, ".concat(_colors.N0, ")"), "var(--ds-border-radius-200, 8px)", "var(--ds-border, ".concat(_colors.N40, ")"), _editorSharedStyles.akEditorSelectedNodeClassName, DATASOURCE_INNER_CONTAINER_CLASSNAME, (0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow]), DATASOURCE_INNER_CONTAINER_CLASSNAME, "var(--ds-border-danger, ".concat(_editorSharedStyles.akEditorDeleteBorder, ")"), _smartCard.SmartCardSharedCssClassName.EMBED_CARD_CONTAINER, _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, _editorSharedStyles.akEditorSelectedNodeClassName, _smartCard.SmartCardSharedCssClassName.LOADER_WRAPPER, (0, _editorSharedStyles.getSelectionStyles)([_editorSharedStyles.SelectionStyle.BoxShadow]), "var(--ds-border-danger, ".concat(_editorSharedStyles.akEditorDeleteBorder, ")"), "var(--ds-background-danger, ".concat(_editorSharedStyles.akEditorDeleteBackground, ")"), "var(--ds-border-danger, ".concat(_editorSharedStyles.akEditorDeleteBorder, ")"), FLOATING_TOOLBAR_LINKPICKER_CLASSNAME);
@@ -20,7 +20,7 @@ var _Layer = _interopRequireDefault(require("../Layer"));
20
20
  function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
21
21
  function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } /** @jsx jsx */ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
22
22
  var packageName = "@atlaskit/editor-common";
23
- var packageVersion = "84.2.0";
23
+ var packageVersion = "84.3.1";
24
24
  var halfFocusRing = 1;
25
25
  var dropOffset = '0, 8';
26
26
  var DropList = /*#__PURE__*/function (_Component) {
@@ -19,29 +19,21 @@ var canApplyAnnotationOnRange = exports.canApplyAnnotationOnRange = function can
19
19
  if (isNaN(from + to) || to - from <= 0 || to < 0 || from < 0) {
20
20
  return false;
21
21
  }
22
- var inlineCard = schema.nodes.inlineCard;
23
22
  var foundInvalid = false;
24
23
  doc.nodesBetween(rangeSelection.from, rangeSelection.to, function (node, _pos, parent) {
25
24
  // Special exception for hardBreak nodes
26
25
  if (schema.nodes.hardBreak === node.type) {
27
26
  return false;
28
27
  }
28
+
29
29
  // For block elements or text nodes, we want to check
30
30
  // if annotations are allowed inside this tree
31
31
  // or if we're leaf and not text
32
-
33
- if ((0, _platformFeatureFlags.getBooleanFF)('platform.editor.allow-inline-comments-for-inline-nodes')) {
34
- if ((0, _platformFeatureFlags.getBooleanFF)('platform.editor.allow-inline-comments-for-inline-nodes-round-2_ctuxz')) {
35
- var isAllowedInlineNode = ['emoji', 'status', 'date', 'mention', 'inlineCard'].includes(node.type.name);
36
- if (node.isInline && !node.isText && !isAllowedInlineNode || node.isLeaf && !node.isText && !isAllowedInlineNode || node.isText && !(parent !== null && parent !== void 0 && parent.type.allowsMarkType(schema.marks.annotation))) {
37
- foundInvalid = true;
38
- return false;
39
- }
40
- } else {
41
- if (node.isInline && !node.isText && node.type !== inlineCard || node.isLeaf && !node.isText && node.type !== inlineCard || node.isText && !(parent !== null && parent !== void 0 && parent.type.allowsMarkType(schema.marks.annotation))) {
42
- foundInvalid = true;
43
- return false;
44
- }
32
+ if ((0, _platformFeatureFlags.fg)('editor_inline_comments_on_inline_nodes')) {
33
+ var isAllowedInlineNode = ['emoji', 'status', 'date', 'mention', 'inlineCard'].includes(node.type.name);
34
+ if (node.isInline && !node.isText && !isAllowedInlineNode || node.isLeaf && !node.isText && !isAllowedInlineNode || node.isText && !(parent !== null && parent !== void 0 && parent.type.allowsMarkType(schema.marks.annotation))) {
35
+ foundInvalid = true;
36
+ return false;
45
37
  }
46
38
  } else {
47
39
  if (node.isInline && !node.isText || node.isLeaf && !node.isText || node.isText && !(parent !== null && parent !== void 0 && parent.type.allowsMarkType(schema.marks.annotation))) {
@@ -111,7 +103,7 @@ function containsAnyAnnotations(slice, state) {
111
103
  function getRangeInlineNodeNames(_ref) {
112
104
  var doc = _ref.doc,
113
105
  pos = _ref.pos;
114
- if (!(0, _platformFeatureFlags.getBooleanFF)('platform.editor.allow-inline-comments-for-inline-nodes-round-2_ctuxz')) {
106
+ if (!(0, _platformFeatureFlags.fg)('editor_inline_comments_on_inline_nodes')) {
115
107
  return undefined;
116
108
  }
117
109
  var nodeNames = new Set();
@@ -129,13 +121,13 @@ function getRangeInlineNodeNames(_ref) {
129
121
  /**
130
122
  * This function returns a list of node types that are wrapped by an annotation mark.
131
123
  *
132
- * The `undefined` will be returned if `platform.editor.allow-inline-comments-for-inline-nodes-round-2_ctuxz` is off.
124
+ * The `undefined` will be returned if `editor_inline_comments_on_inline_nodes` is off.
133
125
  *
134
126
  * @todo: Do not forget to remove `undefined` when the
135
- * `platform.editor.allow-inline-comments-for-inline-nodes-round-2_ctuxz` is removed.
127
+ * `editor_inline_comments_on_inline_nodes` is removed.
136
128
  */
137
129
  function getAnnotationInlineNodeTypes(state, annotationId) {
138
- if (!(0, _platformFeatureFlags.getBooleanFF)('platform.editor.allow-inline-comments-for-inline-nodes-round-2_ctuxz')) {
130
+ if (!(0, _platformFeatureFlags.fg)('editor_inline_comments_on_inline_nodes')) {
139
131
  return undefined;
140
132
  }
141
133
  var mark = state.schema.marks.annotation.create({
@@ -1152,7 +1152,7 @@ var _table = require("./table");
1152
1152
  var _compareNodes = require("./compareNodes");
1153
1153
  var _compose = require("./compose");
1154
1154
  var _isTextInput = require("./is-text-input");
1155
- var _whitespace = require("./whitespace");
1155
+ var _whitespace = require("../whitespace");
1156
1156
  var _shouldForceTracking = require("./should-force-tracking");
1157
1157
  var _getModeFromTheme = require("./getModeFromTheme");
1158
1158
  var _getPerformanceOptions = require("./get-performance-options");
@@ -1181,6 +1181,10 @@ var _insertNodeIntoOrderedList = require("./insert-node-into-ordered-list");
1181
1181
  var _wrapSelectionIn = require("./wrap-selection-in");
1182
1182
  var _calculateToolbarPosition = require("./calculate-toolbar-position");
1183
1183
  var _nodesByLocalIds = require("./nodes-by-localIds");
1184
+ /**
1185
+ * @deprecated - [ED-23844] moving to own entry point @atlaskit/editor-common/whitespace
1186
+ */
1187
+
1184
1188
  // prosemirror-history does not export its plugin key
1185
1189
  var pmHistoryPluginKey = exports.pmHistoryPluginKey = 'history$';
1186
1190
  function shallowEqual() {
@@ -5,5 +5,8 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  exports.GUTTER_SIZE_MOBILE_IN_PX = exports.GUTTER_SIZE_IN_PX = exports.GUTTER_SELECTOR = void 0;
7
7
  var GUTTER_SIZE_IN_PX = exports.GUTTER_SIZE_IN_PX = 120; // Default gutter size
8
+ /**
9
+ * @deprecated - [ED-23844] only used in Editor Core
10
+ */
8
11
  var GUTTER_SIZE_MOBILE_IN_PX = exports.GUTTER_SIZE_MOBILE_IN_PX = 36; // Gutter size for Mobile
9
12
  var GUTTER_SELECTOR = exports.GUTTER_SELECTOR = '#editor-scroll-gutter';