@atlaskit/editor-core 226.4.0 → 226.4.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,48 @@
1
1
  # @atlaskit/editor-core
2
2
 
3
+ ## 226.4.2
4
+
5
+ ### Patch Changes
6
+
7
+ - [`0927c3666c010`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/0927c3666c010) -
8
+ Upgrade `uuid` from `3.x` to `11.1.1` to remediate GHSA-w5hq-g745-h8pq / SNYK-JS-UUID-16133035.
9
+
10
+ `uuid@11` removed the deep subpath exports (`uuid/v4`, `uuid/v1`, `uuid/v5`) and the default
11
+ export, so all internal call sites were migrated to named imports:
12
+
13
+ ```diff
14
+ -import uuid from 'uuid/v4';
15
+ +import { v4 as uuid } from 'uuid';
16
+
17
+ -import uuid from 'uuid';
18
+ +import { v4 as uuid } from 'uuid';
19
+ ```
20
+
21
+ With the exception of `@atlassian/integrations` (below), this is an internal implementation change
22
+ only - no public API, export, or entrypoint changed. UUID generation behaviour is unchanged
23
+ (`uuid@3`'s default export was already `v4`).
24
+
25
+ `@atlassian/integrations` declares `uuid` as a peer dependency, so its declared range moved from
26
+ `^3.1.0` to `^11.1.1`. That is a peer dependency declaration change, hence `minor` rather than
27
+ `patch` for that package.
28
+
29
+ The following `platform/packages/ai-mate` packages were also touched, but are all `private: true`
30
+ and so are intentionally not listed in the frontmatter above:
31
+ - `@atlassian/csm-assistance-service` - bumped its explicit `uuid` dependency from `npm:^9.0.0` to
32
+ `npm:^11.1.1` (`9.0.1` is also within the advisory's affected range).
33
+ - `@atlassian/csm-guidance-config` - example helper only, migrated to the named `uuid` import.
34
+ - `@atlassian/csm-ui-components` - example helper only, migrated to the named `uuid` import.
35
+
36
+ - Updated dependencies
37
+
38
+ ## 226.4.1
39
+
40
+ ### Patch Changes
41
+
42
+ - [`c744811e22b13`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/c744811e22b13) -
43
+ Clean up feature gate `platform_editor_sentry_breadcrumbs`
44
+ - Updated dependencies
45
+
3
46
  ## 226.4.0
4
47
 
5
48
  ### Minor Changes
@@ -11,7 +11,7 @@ var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends")
11
11
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
12
12
  var _react = _interopRequireWildcard(require("react"));
13
13
  var _isEqual = _interopRequireDefault(require("lodash/isEqual"));
14
- var _v = _interopRequireDefault(require("uuid/v4"));
14
+ var _uuid = require("uuid");
15
15
  var _FabricEditorAnalyticsContext = require("@atlaskit/analytics-namespaced-context/FabricEditorAnalyticsContext");
16
16
  var _useAnalyticsEvents2 = require("@atlaskit/analytics-next/useAnalyticsEvents");
17
17
  var _analytics = require("@atlaskit/editor-common/analytics");
@@ -120,7 +120,7 @@ var useMemoEditorFeatureFlags = function useMemoEditorFeatureFlags(featureFlags)
120
120
  */
121
121
  function CoreEditor(props) {
122
122
  // eslint-disable-next-line @atlaskit/platform/prefer-crypto-random-uuid -- Use crypto.randomUUID instead
123
- var editorSessionId = (0, _react.useRef)((0, _v.default)());
123
+ var editorSessionId = (0, _react.useRef)((0, _uuid.v4)());
124
124
  var data = (0, _react.useMemo)(function () {
125
125
  return {
126
126
  packageName: _versionWrapper.name,
@@ -14,14 +14,12 @@ var _getPrototypeOf2 = _interopRequireDefault(require("@babel/runtime/helpers/ge
14
14
  var _inherits2 = _interopRequireDefault(require("@babel/runtime/helpers/inherits"));
15
15
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
16
16
  var _react = _interopRequireDefault(require("react"));
17
- var _uuid = _interopRequireDefault(require("uuid"));
17
+ var _uuid = require("uuid");
18
18
  var _analyticsNextStableReactContext = _interopRequireDefault(require("@atlaskit/analytics-next-stable-react-context"));
19
19
  var _analytics = require("@atlaskit/editor-common/analytics");
20
20
  var _coreUtils = require("@atlaskit/editor-common/core-utils");
21
21
  var _intlErrorBoundary = require("@atlaskit/editor-common/intl-error-boundary");
22
22
  var _monitoring = require("@atlaskit/editor-common/monitoring");
23
- var _fg = require("@atlaskit/platform-feature-flags/fg");
24
- var _componentWithCondition = require("@atlaskit/platform-feature-flags-react/component-with-condition");
25
23
  var _outdatedBrowsers = require("../utils/outdatedBrowsers");
26
24
  var _WithEditorView = require("./WithEditorView");
27
25
  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; }
@@ -51,7 +49,7 @@ var ErrorBoundaryWithEditorView = exports.ErrorBoundaryWithEditorView = /*#__PUR
51
49
  case 1:
52
50
  product = _context.sent;
53
51
  error = analyticsErrorPayload.error, errorInfo = analyticsErrorPayload.errorInfo; // eslint-disable-next-line @atlaskit/platform/prefer-crypto-random-uuid -- Use crypto.randomUUID instead
54
- sharedId = (0, _uuid.default)();
52
+ sharedId = (0, _uuid.v4)();
55
53
  browserInfo = ((_window = window) === null || _window === void 0 || (_window = _window.navigator) === null || _window === void 0 ? void 0 : _window.userAgent) || 'unknown';
56
54
  attributes = {
57
55
  product: product,
@@ -206,8 +204,6 @@ var ErrorBoundaryWithEditorViewWithAnalyticsReactContext = exports.ErrorBoundary
206
204
  return (0, _createClass2.default)(ErrorBoundaryWithEditorViewWithAnalyticsReactContext);
207
205
  }(ErrorBoundaryWithEditorView); // eslint-disable-next-line @typescript-eslint/no-restricted-types
208
206
  (0, _defineProperty2.default)(ErrorBoundaryWithEditorViewWithAnalyticsReactContext, "contextType", _analyticsNextStableReactContext.default);
209
- var _default_1 = (0, _componentWithCondition.componentWithCondition)(function () {
210
- return (0, _fg.fg)('platform_editor_sentry_breadcrumbs');
211
- }, (0, _WithEditorView.WithEditorView)(ErrorBoundaryWithEditorViewWithAnalyticsReactContext), (0, _WithEditorView.WithEditorView)(ErrorBoundaryWithEditorView));
207
+ var _default_1 = (0, _WithEditorView.WithEditorView)(ErrorBoundaryWithEditorViewWithAnalyticsReactContext);
212
208
  // eslint-disable-next-line @atlaskit/volt-strict-mode/no-multiple-exports
213
209
  var _default = exports.default = _default_1;
@@ -13,7 +13,7 @@ var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/sli
13
13
  var _toConsumableArray2 = _interopRequireDefault(require("@babel/runtime/helpers/toConsumableArray"));
14
14
  var _react = _interopRequireWildcard(require("react"));
15
15
  var _reactIntl = require("react-intl");
16
- var _v = _interopRequireDefault(require("uuid/v4"));
16
+ var _uuid = require("uuid");
17
17
  var _analytics = require("@atlaskit/editor-common/analytics");
18
18
  var _coreUtils = require("@atlaskit/editor-common/core-utils");
19
19
  var _eventDispatcher = require("@atlaskit/editor-common/event-dispatcher");
@@ -133,7 +133,7 @@ function ReactEditorView(props) {
133
133
  var canDispatchTransactions = (0, _react.useRef)(true);
134
134
 
135
135
  // eslint-disable-next-line @atlaskit/platform/prefer-crypto-random-uuid -- Use crypto.randomUUID instead
136
- var editorId = (0, _react.useRef)((0, _v.default)());
136
+ var editorId = (0, _react.useRef)((0, _uuid.v4)());
137
137
  var eventDispatcher = (0, _react.useMemo)(function () {
138
138
  return new _eventDispatcher.EventDispatcher();
139
139
  }, []);
@@ -6,4 +6,4 @@ Object.defineProperty(exports, "__esModule", {
6
6
  exports.version = exports.name = void 0;
7
7
  var name = exports.name = "@atlaskit/editor-core";
8
8
  // eslint-disable-next-line @atlaskit/volt-strict-mode/no-multiple-exports
9
- var version = exports.version = "226.3.6";
9
+ var version = exports.version = "226.4.1";
@@ -2,7 +2,7 @@ import _extends from "@babel/runtime/helpers/extends";
2
2
  import React, { useCallback, useMemo, useRef, Fragment } from 'react';
3
3
  import isEqual from 'lodash/isEqual';
4
4
  // eslint-disable-next-line @atlaskit/platform/prefer-crypto-random-uuid -- Use crypto.randomUUID instead
5
- import uuid from 'uuid/v4';
5
+ import { v4 as uuid } from 'uuid';
6
6
  import { FabricEditorAnalyticsContext } from '@atlaskit/analytics-namespaced-context/FabricEditorAnalyticsContext';
7
7
  import { useAnalyticsEvents } from '@atlaskit/analytics-next/useAnalyticsEvents';
8
8
  import { ACTION } from '@atlaskit/editor-common/analytics';
@@ -1,14 +1,12 @@
1
1
  import _defineProperty from "@babel/runtime/helpers/defineProperty";
2
2
  import React from 'react';
3
3
  // eslint-disable-next-line @atlaskit/platform/prefer-crypto-random-uuid -- Use crypto.randomUUID instead
4
- import uuid from 'uuid';
4
+ import { v4 as uuid } from 'uuid';
5
5
  import { default as AnalyticsReactContext } from '@atlaskit/analytics-next-stable-react-context';
6
6
  import { ACTION, ACTION_SUBJECT, editorAnalyticsChannel, EVENT_TYPE } from '@atlaskit/editor-common/analytics';
7
7
  import { getDocStructure } from '@atlaskit/editor-common/core-utils';
8
8
  import { IntlErrorBoundary } from '@atlaskit/editor-common/intl-error-boundary';
9
9
  import { logException } from '@atlaskit/editor-common/monitoring';
10
- import { fg } from '@atlaskit/platform-feature-flags/fg';
11
- import { componentWithCondition } from '@atlaskit/platform-feature-flags-react/component-with-condition';
12
10
  import { isOutdatedBrowser } from '../utils/outdatedBrowsers';
13
11
  import { WithEditorView } from './WithEditorView';
14
12
  // Ignored via go/ees005
@@ -154,6 +152,6 @@ export class ErrorBoundaryWithEditorViewWithAnalyticsReactContext extends ErrorB
154
152
 
155
153
  // eslint-disable-next-line @typescript-eslint/no-restricted-types
156
154
  _defineProperty(ErrorBoundaryWithEditorViewWithAnalyticsReactContext, "contextType", AnalyticsReactContext);
157
- const _default_1 = componentWithCondition(() => fg('platform_editor_sentry_breadcrumbs'), WithEditorView(ErrorBoundaryWithEditorViewWithAnalyticsReactContext), WithEditorView(ErrorBoundaryWithEditorView));
155
+ const _default_1 = WithEditorView(ErrorBoundaryWithEditorViewWithAnalyticsReactContext);
158
156
  // eslint-disable-next-line @atlaskit/volt-strict-mode/no-multiple-exports
159
157
  export default _default_1;
@@ -2,7 +2,7 @@ import _extends from "@babel/runtime/helpers/extends";
2
2
  import React, { useCallback, useLayoutEffect, useMemo, useRef, useState, useEffect } from 'react';
3
3
  import { injectIntl } from 'react-intl';
4
4
  // eslint-disable-next-line @atlaskit/platform/prefer-crypto-random-uuid -- Use crypto.randomUUID instead
5
- import uuid from 'uuid/v4';
5
+ import { v4 as uuid } from 'uuid';
6
6
  import { ACTION, ACTION_SUBJECT, EVENT_TYPE, fireAnalyticsEvent, PLATFORMS } from '@atlaskit/editor-common/analytics';
7
7
  import { isSSR } from '@atlaskit/editor-common/core-utils';
8
8
  import { createDispatch, EventDispatcher } from '@atlaskit/editor-common/event-dispatcher';
@@ -1,3 +1,3 @@
1
1
  export const name = "@atlaskit/editor-core";
2
2
  // eslint-disable-next-line @atlaskit/volt-strict-mode/no-multiple-exports
3
- export const version = "226.3.6";
3
+ export const version = "226.4.1";
@@ -5,7 +5,7 @@ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t =
5
5
  import React, { useCallback, useMemo, useRef, Fragment } from 'react';
6
6
  import isEqual from 'lodash/isEqual';
7
7
  // eslint-disable-next-line @atlaskit/platform/prefer-crypto-random-uuid -- Use crypto.randomUUID instead
8
- import uuid from 'uuid/v4';
8
+ import { v4 as uuid } from 'uuid';
9
9
  import { FabricEditorAnalyticsContext } from '@atlaskit/analytics-namespaced-context/FabricEditorAnalyticsContext';
10
10
  import { useAnalyticsEvents } from '@atlaskit/analytics-next/useAnalyticsEvents';
11
11
  import { ACTION } from '@atlaskit/editor-common/analytics';
@@ -12,14 +12,12 @@ function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstruct
12
12
  function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
13
13
  import React from 'react';
14
14
  // eslint-disable-next-line @atlaskit/platform/prefer-crypto-random-uuid -- Use crypto.randomUUID instead
15
- import uuid from 'uuid';
15
+ import { v4 as uuid } from 'uuid';
16
16
  import { default as AnalyticsReactContext } from '@atlaskit/analytics-next-stable-react-context';
17
17
  import { ACTION, ACTION_SUBJECT, editorAnalyticsChannel, EVENT_TYPE } from '@atlaskit/editor-common/analytics';
18
18
  import { getDocStructure } from '@atlaskit/editor-common/core-utils';
19
19
  import { IntlErrorBoundary } from '@atlaskit/editor-common/intl-error-boundary';
20
20
  import { logException } from '@atlaskit/editor-common/monitoring';
21
- import { fg } from '@atlaskit/platform-feature-flags/fg';
22
- import { componentWithCondition } from '@atlaskit/platform-feature-flags-react/component-with-condition';
23
21
  import { isOutdatedBrowser } from '../utils/outdatedBrowsers';
24
22
  import { WithEditorView } from './WithEditorView';
25
23
  // Ignored via go/ees005
@@ -204,8 +202,6 @@ export var ErrorBoundaryWithEditorViewWithAnalyticsReactContext = /*#__PURE__*/f
204
202
 
205
203
  // eslint-disable-next-line @typescript-eslint/no-restricted-types
206
204
  _defineProperty(ErrorBoundaryWithEditorViewWithAnalyticsReactContext, "contextType", AnalyticsReactContext);
207
- var _default_1 = componentWithCondition(function () {
208
- return fg('platform_editor_sentry_breadcrumbs');
209
- }, WithEditorView(ErrorBoundaryWithEditorViewWithAnalyticsReactContext), WithEditorView(ErrorBoundaryWithEditorView));
205
+ var _default_1 = WithEditorView(ErrorBoundaryWithEditorViewWithAnalyticsReactContext);
210
206
  // eslint-disable-next-line @atlaskit/volt-strict-mode/no-multiple-exports
211
207
  export default _default_1;
@@ -10,7 +10,7 @@ function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length)
10
10
  import React, { useCallback, useLayoutEffect, useMemo, useRef, useState, useEffect } from 'react';
11
11
  import { injectIntl } from 'react-intl';
12
12
  // eslint-disable-next-line @atlaskit/platform/prefer-crypto-random-uuid -- Use crypto.randomUUID instead
13
- import uuid from 'uuid/v4';
13
+ import { v4 as uuid } from 'uuid';
14
14
  import { ACTION, ACTION_SUBJECT, EVENT_TYPE, fireAnalyticsEvent, PLATFORMS } from '@atlaskit/editor-common/analytics';
15
15
  import { isSSR } from '@atlaskit/editor-common/core-utils';
16
16
  import { createDispatch, EventDispatcher } from '@atlaskit/editor-common/event-dispatcher';
@@ -1,3 +1,3 @@
1
1
  export var name = "@atlaskit/editor-core";
2
2
  // eslint-disable-next-line @atlaskit/volt-strict-mode/no-multiple-exports
3
- export var version = "226.3.6";
3
+ export var version = "226.4.1";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-core",
3
- "version": "226.4.0",
3
+ "version": "226.4.2",
4
4
  "description": "A package contains Atlassian editor core functionality",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -64,7 +64,7 @@
64
64
  "@atlaskit/icon": "^37.6.0",
65
65
  "@atlaskit/icon-lab": "^7.8.0",
66
66
  "@atlaskit/link": "^5.1.0",
67
- "@atlaskit/media-card": "^81.9.0",
67
+ "@atlaskit/media-card": "^81.10.0",
68
68
  "@atlaskit/mention": "^27.19.0",
69
69
  "@atlaskit/platform-feature-experiments": "^0.3.0",
70
70
  "@atlaskit/platform-feature-flags": "^2.2.0",
@@ -89,7 +89,7 @@
89
89
  "prop-types": "^15.5.10",
90
90
  "react-loadable": "^5.1.0",
91
91
  "react-transition-group": "^4.4.1",
92
- "uuid": "^3.1.0"
92
+ "uuid": "^11.1.1"
93
93
  },
94
94
  "peerDependencies": {
95
95
  "@atlaskit/editor-common": "^120.13.0",
@@ -154,7 +154,7 @@
154
154
  "@atlaskit/portal": "^6.4.0",
155
155
  "@atlaskit/profilecard": "^26.21.0",
156
156
  "@atlaskit/radio": "^10.2.0",
157
- "@atlaskit/renderer": "^137.3.0",
157
+ "@atlaskit/renderer": "^137.4.0",
158
158
  "@atlaskit/section-message": "^10.2.0",
159
159
  "@atlaskit/spinner": "^20.4.0",
160
160
  "@atlaskit/synchrony-test-helpers": "workspace:^",
@@ -165,7 +165,7 @@
165
165
  "@atlassian/a11y-jest-testing": "^0.17.0",
166
166
  "@atlassian/a11y-playwright-testing": "^0.12.0",
167
167
  "@atlassian/adf-schema-json": "^1.35.0",
168
- "@atlassian/editor-rovo-bridge": "^14.0.0",
168
+ "@atlassian/editor-rovo-bridge": "^14.1.0",
169
169
  "@atlassian/experiment-test-utils": "^0.2.0",
170
170
  "@atlassian/feature-flags-test-utils": "^1.3.0",
171
171
  "@atlassian/search-client": "^2.19.0",
@@ -277,9 +277,6 @@
277
277
  "type": "boolean",
278
278
  "referenceOnly": true
279
279
  },
280
- "platform_editor_sentry_breadcrumbs": {
281
- "type": "boolean"
282
- },
283
280
  "platform_editor_comments_border_radius": {
284
281
  "type": "boolean"
285
282
  },